From 6e6d4c1f5bd8c53e259a51ef1953f384a12bef7d Mon Sep 17 00:00:00 2001 From: Jim McDonough Date: Wed, 16 Jul 2008 12:37:48 -0400 Subject: Allow %u parameters for print job username - use advanced sub Based on 3.0 and 3.2 patch from Bo Yang Bo, please verify this version works for you. (This used to be commit 9e6760cfeaf77e80df3b84004090d934f3c2d574) --- source3/printing/printing.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'source3') diff --git a/source3/printing/printing.c b/source3/printing/printing.c index a425b87907..1016e6183d 100644 --- a/source3/printing/printing.c +++ b/source3/printing/printing.c @@ -2439,9 +2439,11 @@ uint32 print_job_start(struct auth_serversupplied_info *server_info, int snum, fstrcpy(pjob.jobname, jobname); fstrcpy(pjob.user, lp_printjob_username(snum)); - standard_sub_basic(server_info->sanitized_username, - pdb_get_domain(server_info->sam_account), - pjob.user, sizeof(pjob.user)-1); + standard_sub_advanced(sharename, server_info->sanitized_username, + path, server_info->utok.gid, + server_info->sanitized_username, + pdb_get_domain(server_info->sam_account), + pjob.user, sizeof(pjob.user)-1); /* ensure NULL termination */ pjob.user[sizeof(pjob.user)-1] = '\0'; -- cgit