Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

In this compliant solution, in native code, object references are tested for object equality using the IsSameObject() function. The , and the object references tested are return values from the NewGlobalRef() functionglobal references.

Code Block
bgColor#CCCCFF
 

...

Rule

Severity

Likelihood

Remediation Cost

Priority

Level

JNI02-J

Low

Probable

High

P2

L3

Automated Detection

Although it may be possible to automatically detect the use of == or != for comparing object references in native code, in general automatic detection of the wider issue is not feasible. [Is it?]

...

 

...

Image Added Image Added Image Added