From 229d28866bf554e77928ccade55b06a7fdd47382 Mon Sep 17 00:00:00 2001 From: solar Date: Mon, 6 Feb 2006 21:03:39 +0000 Subject: [PATCH] Added comments. --- functions/stdlib/calloc.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/functions/stdlib/calloc.c b/functions/stdlib/calloc.c index 1e568b4..5450b97 100644 --- a/functions/stdlib/calloc.c +++ b/functions/stdlib/calloc.c @@ -15,9 +15,11 @@ 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; -- 2.40.0