From a847f13d7b0c8606471792a50e9c64d1f6bd430c Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Tue, 17 Aug 2010 09:34:27 +0200 Subject: s3: Use pipe_struct->client_id->name for pjob.clientmachine --- source3/printing/printing.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'source3/printing/printing.c') diff --git a/source3/printing/printing.c b/source3/printing/printing.c index 297fdd1d28..4240ddf330 100644 --- a/source3/printing/printing.c +++ b/source3/printing/printing.c @@ -2685,6 +2685,7 @@ static WERROR print_job_spool_file(int snum, uint32_t jobid, WERROR print_job_start(struct auth_serversupplied_info *server_info, struct messaging_context *msg_ctx, + const char *clientmachine, int snum, const char *docname, const char *filename, struct spoolss_DeviceMode *devmode, uint32_t *_jobid) { @@ -2695,8 +2696,6 @@ WERROR print_job_start(struct auth_serversupplied_info *server_info, struct tdb_print_db *pdb = get_print_db_byname(sharename); int njobs; WERROR werr; - const char *clientname; - char addr[INET6_ADDRSTRLEN]; if (!pdb) { return WERR_INTERNAL_DB_CORRUPTION; @@ -2735,11 +2734,7 @@ WERROR print_job_start(struct auth_serversupplied_info *server_info, fstrcpy(pjob.jobname, docname); - clientname = client_name(smbd_server_fd()); - if (strcmp(clientname, "UNKNOWN") == 0) { - clientname = client_addr(smbd_server_fd(),addr,sizeof(addr)); - } - fstrcpy(pjob.clientmachine, clientname); + fstrcpy(pjob.clientmachine, clientmachine); fstrcpy(pjob.user, lp_printjob_username(snum)); standard_sub_advanced(sharename, server_info->sanitized_username, -- cgit