mirror of
https://github.com/xzeldon/htop.git
synced 2025-07-15 05:24:36 +03:00
Revert 5c593fae42
(xCalloc)
calloc() allows 'nmemb' or 'size' to be zero, in which case NULL may be returned. Letting htop die because of either argument being zero doesn't make sense. As a side note: As size_t is unsigned, compiler should be able to optimize conditional (nmemb > 0 && size > 0) to (nmemb && size). This theorically shouldn't increase code size too much.
This commit is contained in:
Reference in New Issue
Block a user