summaryrefslogtreecommitdiff
path: root/source3/printing/printfsp.c
diff options
context:
space:
mode:
authorGerald Carter <jerry@samba.org>2004-10-19 17:05:01 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 10:53:00 -0500
commit293136c04b7eb5293ef18273e13fca00c85bb5f0 (patch)
tree122bc0f24b690926d2f43aad98401052ce4f8ace /source3/printing/printfsp.c
parentf2aca08c653a61dc4d6e99263dda7b649ef648b0 (diff)
downloadsamba-293136c04b7eb5293ef18273e13fca00c85bb5f0.tar.gz
samba-293136c04b7eb5293ef18273e13fca00c85bb5f0.tar.bz2
samba-293136c04b7eb5293ef18273e13fca00c85bb5f0.zip
r3067: patch based on volker's initial work in trunk that fixes the queu update problem when using the background daemon
(This used to be commit de7af09e727e744aa27af85ef7c0f73ed5c1550a)
Diffstat (limited to 'source3/printing/printfsp.c')
-rw-r--r--source3/printing/printfsp.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/source3/printing/printfsp.c b/source3/printing/printfsp.c
index 0b6d4fdbe1..7c5de46870 100644
--- a/source3/printing/printfsp.c
+++ b/source3/printing/printfsp.c
@@ -53,16 +53,16 @@ files_struct *print_fsp_open(connection_struct *conn, char *fname)
}
/* Convert to RAP id. */
- fsp->rap_print_jobid = pjobid_to_rap(SNUM(conn), jobid);
+ fsp->rap_print_jobid = pjobid_to_rap(lp_const_servicename(SNUM(conn)), jobid);
if (fsp->rap_print_jobid == 0) {
/* We need to delete the entry in the tdb. */
- pjob_delete(SNUM(conn), jobid);
+ pjob_delete(lp_const_servicename(SNUM(conn)), jobid);
file_free(fsp);
return NULL;
}
/* setup a full fsp */
- fsp->fd = print_job_fd(SNUM(conn),jobid);
+ fsp->fd = print_job_fd(lp_const_servicename(SNUM(conn)),jobid);
GetTimeOfDay(&fsp->open_time);
fsp->vuid = current_user.vuid;
fsp->size = 0;
@@ -77,7 +77,7 @@ files_struct *print_fsp_open(connection_struct *conn, char *fname)
fsp->sent_oplock_break = NO_BREAK_SENT;
fsp->is_directory = False;
fsp->directory_delete_on_close = False;
- string_set(&fsp->fsp_name,print_job_fname(SNUM(conn),jobid));
+ string_set(&fsp->fsp_name,print_job_fname(lp_const_servicename(SNUM(conn)),jobid));
fsp->wbmpx_ptr = NULL;
fsp->wcp = NULL;
SMB_VFS_FSTAT(fsp,fsp->fd, &sbuf);
@@ -96,7 +96,7 @@ print a file - called on closing the file
void print_fsp_end(files_struct *fsp, BOOL normal_close)
{
uint32 jobid;
- int snum;
+ fstring sharename;
if (fsp->share_mode == FILE_DELETE_ON_CLOSE) {
/*
@@ -110,7 +110,7 @@ void print_fsp_end(files_struct *fsp, BOOL normal_close)
string_free(&fsp->fsp_name);
}
- if (!rap_to_pjobid(fsp->rap_print_jobid, &snum, &jobid)) {
+ if (!rap_to_pjobid(fsp->rap_print_jobid, sharename, &jobid)) {
DEBUG(3,("print_fsp_end: Unable to convert RAP jobid %u to print jobid.\n",
(unsigned int)fsp->rap_print_jobid ));
return;