svn commit: samba r4089 - in branches/SAMBA_3_0/source/printing: .

jerry at samba.org jerry at samba.org
Tue Dec 7 19:00:46 GMT 2004


Author: jerry
Date: 2004-12-07 19:00:45 +0000 (Tue, 07 Dec 2004)
New Revision: 4089

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=4089

Log:
fix logic error in add_a_form() that only compared N characters instead of the entire form name
Modified:
   branches/SAMBA_3_0/source/printing/nt_printing.c


Changeset:
Modified: branches/SAMBA_3_0/source/printing/nt_printing.c
===================================================================
--- branches/SAMBA_3_0/source/printing/nt_printing.c	2004-12-07 18:25:53 UTC (rev 4088)
+++ branches/SAMBA_3_0/source/printing/nt_printing.c	2004-12-07 19:00:45 UTC (rev 4089)
@@ -593,8 +593,7 @@
 	
 	unistr2_to_ascii(form_name, &form->name, sizeof(form_name)-1);
 	for (n=0; n<*count; n++) {
-		if (!strncmp((*list)[n].name, form_name, strlen(form_name))) {
-			DEBUG(103, ("NT workaround, [%s] already exists\n", form_name));
+		if ( strequal((*list)[n].name, form_name) ) {
 			update=True;
 			break;
 		}
@@ -618,6 +617,9 @@
 	(*list)[n].right=form->right;
 	(*list)[n].bottom=form->bottom;
 
+	DEBUG(6,("add_a_form: Successfully %s form [%s]\n", 
+		update ? "updated" : "added", form_name));
+
 	return True;
 }
 



More information about the samba-cvs mailing list