Have you also checked anotherfunction() ?
In any case, C ++ pointer addresses, such as C pointer addresses, are usually virtual on most platforms and do not correspond directly to memory cells. Therefore, the value can be very small or unusual.
In addition, they will always be true, since 0 is NULL , an invalid pointer, and anything greater than 0 is true
source share