Another malloc without NULL check

Claudia Moroder claudiamoroder at st-ulrich.suedtirol.net
Sun Aug 5 20:11:10 GMT 2001


Hello,

i found two problems with malloc/free

1. cli_spoolss.c

decode_printer_info_0

inf = malloc(...)

and inf is used without a NULL check.
It is also strange that all other allocations in this files are made through
talloc.


2. in clientgen.c

I don't remember the exact position, because now I am in windows , but ..

cli is allocatd with malloc
few lines later the buffers are allocated with malloc and are tested.
If one of the buffer allocations fails the function return NULL without
freeing the first buffer ( if the second failed ) and without releasing cli.

BYe

Andreas





More information about the samba-technical mailing list