svn commit: samba r16371 - in branches/SAMBA_3_0/source/rpc_parse: .
jra at samba.org
jra at samba.org
Mon Jun 19 22:55:04 GMT 2006
Author: jra
Date: 2006-06-19 22:55:03 +0000 (Mon, 19 Jun 2006)
New Revision: 16371
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=16371
Log:
Fix Klocwork #1048.
Jeremy.
Modified:
branches/SAMBA_3_0/source/rpc_parse/parse_ntsvcs.c
Changeset:
Modified: branches/SAMBA_3_0/source/rpc_parse/parse_ntsvcs.c
===================================================================
--- branches/SAMBA_3_0/source/rpc_parse/parse_ntsvcs.c 2006-06-19 22:54:58 UTC (rev 16370)
+++ branches/SAMBA_3_0/source/rpc_parse/parse_ntsvcs.c 2006-06-19 22:55:03 UTC (rev 16371)
@@ -299,8 +299,12 @@
q_u->buffer_size = 0x000000a8;
- if ( UNMARSHALLING(ps) )
+ if ( UNMARSHALLING(ps) ) {
q_u->buffer = TALLOC_ARRAY(get_talloc_ctx(), uint8, q_u->buffer_size );
+ if (!q_u->buffer) {
+ return False;
+ }
+ }
if ( !prs_uint8s(True, "buffer", ps, depth, q_u->buffer, q_u->buffer_size) )
return False;
@@ -329,8 +333,12 @@
if ( !prs_align(ps) )
return False;
- if ( UNMARSHALLING(ps) )
+ if ( UNMARSHALLING(ps) ) {
r_u->buffer = TALLOC_ARRAY(get_talloc_ctx(), uint8, r_u->buffer_size );
+ if (!r_u->buffer) {
+ return False;
+ }
+ }
if ( !prs_uint8s(True, "buffer", ps, depth, r_u->buffer, r_u->buffer_size) )
return False;
More information about the samba-cvs
mailing list