问题描述
- 请教下:在JNI某类构造方法里添加了PdhAddCounter,返回值一直不正确!
- 在JNI某个类的构造方法里添加了PdhAddCounter(query_TEXT(""PhysicalDisk(_Total)Disk Bytes/sec"") NULL &counter);调式不报错,可java程序没运行到该类构造方法时,就停住了,不报错,也不往下执行!也就是停在该方法上。其返回值验证都没有到,请高手赐教解决方法。
解决方案
如果用c++程序调用dll是否也问题。先看是dll代码问题还是jni
解决方案二:
修正下上面是:PdhAddCounter(query_TEXT(""PhysicalDisk(_Total)Disk Bytes/sec"") NULL &counter);
解决方案三:
修正下上面是:PdhAddCounter(query_TEXT(""PhysicalDisk(_Total)Disk Bytes/sec"") NULL &counter);
解决方案四:
修正下上面是:PdhAddCounter(query_TEXT(""PhysicalDisk(_Total)Disk Bytes/sec"") NULL &counter);
解决方案五:
修正下上面是:PdhAddCounter(query_TEXT(""PhysicalDisk(_Total)Disk Bytes/sec"") NULL &counter);
解决方案六:
修正下上面是:PdhAddCounter(query_TEXT(""PhysicalDisk(_Total)Disk Bytes/sec"") NULL &counter);
解决方案七:
修正下上面是:PdhAddCounter(query_TEXT(""PhysicalDisk(_Total)Disk Bytes/sec"") NULL &counter);
解决方案八:
修正下上面是:PdhAddCounter(query_TEXT(""PhysicalDisk(_Total)Disk Bytes/sec"") NULL &counter);
解决方案九:
修正下上面是:PdhAddCounter(query_TEXT(""PhysicalDisk(_Total)Disk Bytes/sec"") NULL &counter);
解决方案十:
修正下上面是:PdhAddCounter(query_TEXT(""PhysicalDisk(_Total)Disk Bytes/sec"") NULL &counter);