PR: 9664
fix close method so if an app directly calls close(), finalize wont blow up.
This commit is contained in:
1 parent
bee745af0d
commit
00e64ab40d
1 file changed
+3
-1
@@ -34,7 +34,9 @@ public class Pdh extends Win32Bindings {
|
||||
h_counter = -1l;
|
||||
}
|
||||
|
||||
pdhCloseQuery(h_query);
|
||||
if (h_query != -1l) {
|
||||
pdhCloseQuery(h_query);
|
||||
}
|
||||
}
|
||||
|
||||
public double getSingleValue(String cp) throws Win32Exception {
|
||||
|
||||
Reference in new issue
Block a user