logoalt Hacker News

comexlast Thursday at 6:24 PM3 repliesview on HN

If you call malloc(0) multiple times (without freeing in between) and get -1 each time, then the pointer is not unique.


Replies

bobmcnamaralast Thursday at 10:57 PM

But do we need a unique pointer or merely a pointer that is disjoint from all objects?

show 2 replies
mystified5016yesterday at 2:09 PM

Null is not a unique pointer, it's a contant like -1

It returns multiple types of null pointer

show 1 reply