]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
r1484: BUG 1520: work around bug in xp sp2 rc2 where the client sends a fnpcn() reque...
authorGerald Carter <jerry@samba.org>
Tue, 13 Jul 2004 19:20:37 +0000 (19:20 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 15:52:12 +0000 (10:52 -0500)
source/rpc_server/srv_spoolss_nt.c

index 06ba5435976cdcd2f46fed469a4b115e7a8ae13b..08553bfe654e97a5377c9662ca0bbbc227680e1a 100644 (file)
@@ -3725,6 +3725,12 @@ static WERROR printserver_notify_info(pipes_struct *p, POLICY_HND *hnd,
        info->data=NULL;
        info->count=0;
 
+       /* a bug in xp sp2 rc2 causes it to send a fnpcn request without 
+          sending a ffpcn() request first */
+
+       if ( !option )
+               return WERR_BADFID;
+
        for (i=0; i<option->count; i++) {
                option_type=&(option->ctr.type[i]);
                
@@ -3787,6 +3793,12 @@ static WERROR printer_notify_info(pipes_struct *p, POLICY_HND *hnd, SPOOL_NOTIFY
        info->data=NULL;
        info->count=0;
 
+       /* a bug in xp sp2 rc2 causes it to send a fnpcn request without 
+          sending a ffpcn() request first */
+
+       if ( !option )
+               return WERR_BADFID;
+
        get_printer_snum(p, hnd, &snum);
 
        for (i=0; i<option->count; i++) {