From 620f2e608f70ba92f032720c031283d295c5c06a Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Tue, 7 Dec 2004 18:25:53 +0000 Subject: r4088: Get medieval on our ass about malloc.... :-). Take control of all our allocation functions so we can funnel through some well known functions. Should help greatly with malloc checking. HEAD patch to follow. Jeremy. --- source/smbd/blocking.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source/smbd/blocking.c') diff --git a/source/smbd/blocking.c b/source/smbd/blocking.c index e143999a785..0e71174a2ee 100644 --- a/source/smbd/blocking.c +++ b/source/smbd/blocking.c @@ -106,12 +106,12 @@ BOOL push_blocking_lock_request( char *inbuf, int length, int lock_timeout, * the expiration time here. */ - if((blr = (blocking_lock_record *)malloc(sizeof(blocking_lock_record))) == NULL) { + if((blr = SMB_MALLOC_P(blocking_lock_record)) == NULL) { DEBUG(0,("push_blocking_lock_request: Malloc fail !\n" )); return False; } - if((blr->inbuf = (char *)malloc(length)) == NULL) { + if((blr->inbuf = (char *)SMB_MALLOC(length)) == NULL) { DEBUG(0,("push_blocking_lock_request: Malloc fail (2)!\n" )); SAFE_FREE(blr); return False; -- cgit