Show Navigation
Conversation
Notices
-
Ah, C++. Was trying to figure out why a access to a member of a class segfaulted. Noticed the rather weird pointer value 0x00000030. And yes, I did a parent_object->field() to get reference to the object I was interested in and parent_object was nullptr. But because all that method did was return a field which has a fixed offset in the object obviously the compiler just did pointer arithmetic without checking for null pointers. Makes perfect sense but it is a good reminder that null pointer dereference does not _need_ to segfault immediately.