svn commit: samba r14786 - in branches/SAMBA_3_0/source/rpc_server:
.
jra at samba.org
jra at samba.org
Wed Mar 29 23:35:18 GMT 2006
Author: jra
Date: 2006-03-29 23:35:16 +0000 (Wed, 29 Mar 2006)
New Revision: 14786
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=14786
Log:
Fix coverity #275. null deref.
Jeremy.
Modified:
branches/SAMBA_3_0/source/rpc_server/srv_spoolss_nt.c
Changeset:
Modified: branches/SAMBA_3_0/source/rpc_server/srv_spoolss_nt.c
===================================================================
--- branches/SAMBA_3_0/source/rpc_server/srv_spoolss_nt.c 2006-03-29 23:32:49 UTC (rev 14785)
+++ branches/SAMBA_3_0/source/rpc_server/srv_spoolss_nt.c 2006-03-29 23:35:16 UTC (rev 14786)
@@ -723,14 +723,21 @@
if (!make_systemtime(&systime, gmtime((time_t *)msg->notify.data))) {
DEBUG(5, ("notify_system_time: unable to make systemtime\n"));
+ prs_mem_free(&ps);
return;
}
- if (!spoolss_io_system_time("", &ps, 0, &systime))
+ if (!spoolss_io_system_time("", &ps, 0, &systime)) {
+ prs_mem_free(&ps);
return;
+ }
data->notify_data.data.length = prs_offset(&ps);
data->notify_data.data.string = TALLOC(mem_ctx, prs_offset(&ps));
+ if (!data->notify_data.data.string) {
+ prs_mem_free(&ps);
+ return;
+ }
prs_copy_all_data_out((char *)data->notify_data.data.string, &ps);
More information about the samba-cvs
mailing list