* src/alloc.c (lisp_malloc): Document that NBYTES must be
positive, and omit a needless runtime check. This pacifies a
false alarm with gcc 11.2.1 -Wanalyzer-possible-null-dereference.
/* Like malloc but used for allocating Lisp data. NBYTES is the
number of bytes to allocate, TYPE describes the intended use of the
- allocated memory block (for strings, for conses, ...). */
+ allocated memory block (for strings, for conses, ...).
+ NBYTES must be positive. */
#if ! USE_LSB_TAG
void *lisp_malloc_loser EXTERNALLY_VISIBLE;
#endif
MALLOC_UNBLOCK_INPUT;
- if (!val && nbytes)
+ if (!val)
memory_full (nbytes);
MALLOC_PROBE (nbytes);
return val;