]> pd.if.org Git - pdclib/commitdiff
Added comments.
authorsolar <unknown>
Mon, 6 Feb 2006 21:03:39 +0000 (21:03 +0000)
committersolar <unknown>
Mon, 6 Feb 2006 21:03:39 +0000 (21:03 +0000)
functions/stdlib/calloc.c

index 1e568b4303551e4467ef721d35820082612d5981..5450b978f07a83c92e7284d5856930792d61bea9 100644 (file)
 
 void * calloc( size_t nmemb, size_t size )
 {
+    /* assign memory for nmemb elements of given size */
     void * rc = malloc( nmemb * size );
     if ( rc != NULL )
     {
+        /* zero-initialize the memory */
         memset( rc, 0, nmemb * size );
     }
     return rc;