]> git.ipfire.org Git - thirdparty/cups.git/commitdiff
The scheduler incorrectly started jobs while canceling multiple jobs (STR #4648)
authormsweet <msweet@a1ca3aef-8c08-0410-bb20-df032aa958be>
Tue, 7 Jul 2015 17:24:06 +0000 (17:24 +0000)
committermsweet <msweet@a1ca3aef-8c08-0410-bb20-df032aa958be>
Tue, 7 Jul 2015 17:24:06 +0000 (17:24 +0000)
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/trunk@12777 a1ca3aef-8c08-0410-bb20-df032aa958be

CHANGES-2.0.txt
scheduler/ipp.c
scheduler/job.c

index 86256ecabdd1984ffa15f893980602f88b2b1377..ff74331c65c2add35e70c963da5238c9aef298aa 100644 (file)
@@ -9,6 +9,8 @@ CHANGES IN CUPS V2.0.4
        - The scheduler did not start all pending jobs at once (STR #4646)
        - The web search incorrectly searched time-at-xxx values (STR #4652)
        - Fixed an RPM spec file issue (STR #4657)
+       - The scheduler incorrectly started jobs while canceling multiple jobs
+         (STR #4648)
        - Documentation changes (STR #4651)
 
 
index 57c882d056d30f3970d90881fae455bf2d79e795..0e9249d8d3678de49246ac9b25ecbe49f7706b39 100644 (file)
@@ -3312,6 +3312,8 @@ cancel_all_jobs(cupsd_client_t  *con,     /* I - Client connection */
   }
 
   con->response->request.status.status_code = IPP_OK;
+
+  cupsdCheckJobs();
 }
 
 
index 82c5306d635be268d837226f8ab9ccfac6eaf573..dd6d30cafb4e630f6fa83a8c7191838ad0ee4a7d 100644 (file)
@@ -213,8 +213,6 @@ cupsdCancelJobs(const char *dest,   /* I - Destination to cancel */
                         "Job canceled by user.");
     }
   }
-
-  cupsdCheckJobs();
 }
 
 
@@ -3526,13 +3524,6 @@ finalize_job(cupsd_job_t *job,           /* I - Job */
 
   job->printer->job = NULL;
   job->printer      = NULL;
-
- /*
-  * Try printing another job...
-  */
-
-  if (printer_state != IPP_PRINTER_STOPPED)
-    cupsdCheckJobs();
 }
 
 
@@ -4849,6 +4840,8 @@ update_job(cupsd_job_t *job)              /* I - Job to check */
                *ptr;                   /* Pointer update... */
   int          loglevel,               /* Log level for message */
                event = 0;              /* Events? */
+  cupsd_printer_t *printer = job->printer;
+                                       /* Printer */
   static const char * const levels[] = /* Log levels */
                {
                  "NONE",
@@ -5222,10 +5215,11 @@ update_job(cupsd_job_t *job)            /* I - Job to check */
     finalize_job(job, 1);
 
    /*
-    * Check for new jobs...
+    * Try printing another job...
     */
 
-    cupsdCheckJobs();
+    if (printer->state != IPP_PRINTER_STOPPED)
+      cupsdCheckJobs();
   }
 }