The lprng printing back-end is truncating the print job filename in the
lpq output, which means that Samba is not able to determine the back-end
job ID for a newly submitted print job.
Remove the unneeded spoolss job ID from the print job file name to
ensure the job filename is not truncated. Also log these warnings at a
higher log level.
Autobuild-User(master): David Disseldorp <ddiss@samba.org>
Autobuild-Date(master): Wed Aug 29 14:25:13 CEST 2012 on sn-devel-104
ret = 0;
}
if (pjob->sysjob == -1) {
- DEBUG(0, ("failed to get sysjob for job %u (%s), tracking as "
+ DEBUG(2, ("failed to get sysjob for job %u (%s), tracking as "
"Unix job\n", pjob->jobid, jobname));
}
}
slprintf(pjob->filename, sizeof(pjob->filename)-1,
- "%s/%s%.8u.XXXXXX", lp_pathname(talloc_tos(), snum),
- PRINT_SPOOL_PREFIX, (unsigned int)jobid);
+ "%s/%sXXXXXX", lp_pathname(talloc_tos(), snum),
+ PRINT_SPOOL_PREFIX);
pjob->fd = mkstemp(pjob->filename);
if (pjob->fd == -1) {