Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

JNI and return bool statement problem  RSS feed

Kacper Lekstan
Posts: 1
Eclipse IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is my first post here so Hello Everyone

I have small (I guess) problem with c++ but its directly connected with JNI... so the problem is: I wrote a program in Java to maintain some kind of hardware box... to do this I had to use JNI because there was no any jar, only one *.lib, so base on lib functions I wrote java class and generete c++ headerer and I created c++ lib to have possibility to use nativ lib. Till this moment everything was fine but i had to return box and now im trying to write some kind of nativ virtual library so I can simulate this box and here is the problem:

as I marked higher return of ReadDigitalChannel(Channel); is always true no matter what I put into its body

thank you for any tips/solution/clue



the simplest answer is: C have no bool statement so changing return type into int solving problem

Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!