#47 most returns from malloc/realloc not checked

open
nobody
None
5
2006-02-13
2006-02-13
No

Many calls to malloc and realloc are not checked for
returning NULL. As a result, when the system is
running low on memory, aide fails because of a NULL
pointer.

All returns from malloc and realloc should be checked
for NULL. When NULL is returned, aide should fail with
an "out of memory" error message instread of a
segmentation violation or bus error due to a bad NULL
pointer reference.

Discussion