diff options
author | Jeremy Allison <jra@samba.org> | 2003-03-01 00:48:09 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2003-03-01 00:48:09 +0000 |
commit | d29c6853dd0c43825b3775020076f34faa5cd329 (patch) | |
tree | 47f330a3b2c0bd020eb5060443d972a61eee399b /source/printing | |
parent | 3780d127313ad9f4411751d34fd6e1d96b1422cf (diff) | |
download | samba-d29c6853dd0c43825b3775020076f34faa5cd329.tar.gz samba-d29c6853dd0c43825b3775020076f34faa5cd329.tar.xz samba-d29c6853dd0c43825b3775020076f34faa5cd329.zip |
Ensure added jobs increment total_jobs.
Jeremy.
Diffstat (limited to 'source/printing')
-rw-r--r-- | source/printing/printing.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/source/printing/printing.c b/source/printing/printing.c index c9612ab3a91..26ea52e35a3 100644 --- a/source/printing/printing.c +++ b/source/printing/printing.c @@ -916,6 +916,9 @@ static void print_queue_update(int snum) SAFE_FREE(tstruct.queue); + DEBUG(10,("print_queue_update: printer %s INFO/total_jobs = %d\n", + printer_name, tstruct.total_jobs )); + tdb_store_int32(pdb->tdb, "INFO/total_jobs", tstruct.total_jobs); get_queue_status(snum, &old_status); @@ -1733,6 +1736,9 @@ to open spool file %s.\n", pjob.filename)); pjob_store(snum, jobid, &pjob); + /* Ensure we keep a rough count of the number of total jobs... */ + tdb_change_int32_atomic(pdb->tdb, "INFO/total_jobs", &njobs, 1); + release_print_db(pdb); return jobid; |