[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-core-devel
Subject: the final say about malloc, etc.
From: Alex Zepeda <jazepeda () pacbell ! net>
Date: 2000-08-01 5:59:42
[Download RAW message or body]
From the malloc, etc man page:
The calloc() function allocates space for number objects, each size bytes
in length. The result is identical to calling malloc() with an argument
of ``number * size'', with the exception that the allocated memory is ex-
plicitly initialized to zero bytes.
...
STANDARDS
The malloc(), calloc(), realloc() and free() functions conform to ISO
9899: 1990 (``ISO C'').
Note the second to last sentence. Memory allocated via malloc is not
guaranteed to be zero'd out. Hence one should really initialize all
memory before use.
- alex
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic