param: rename lp function and variable from "printcommand" to "print_command"
authorGarming Sam <garming@catalyst.net.nz>
Tue, 4 Feb 2014 02:09:07 +0000 (15:09 +1300)
committerJeremy Allison <jra@samba.org>
Sat, 8 Feb 2014 00:19:14 +0000 (16:19 -0800)
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
lib/param/param_functions.c
lib/param/param_table.c
source3/param/loadparm.c
source3/printing/print_generic.c
source3/utils/testparm.c

index b59a4ae20a147826c6e782eae731084597513422..2fa8c5911936de336defea4c074e4cd8b0bdc78b 100644 (file)
@@ -56,7 +56,7 @@ FN_LOCAL_STRING(username, username)
 FN_LOCAL_LIST(invalid_users, invalid_users)
 FN_LOCAL_LIST(valid_users, valid_users)
 FN_LOCAL_LIST(admin_users, admin_users)
-FN_LOCAL_STRING(printcommand, printcommand)
+FN_LOCAL_STRING(print_command, print_command)
 FN_LOCAL_STRING(lpq_command, lpq_command)
 FN_LOCAL_STRING(lprm_command, lprm_command)
 FN_LOCAL_STRING(lppause_command, lppause_command)
index 4c2caee343021c405e5c93aa68c5ea4d0175eee6..4d2b65779950dcb14751c106522f46e960bb4872 100644 (file)
@@ -2158,7 +2158,7 @@ static struct parm_struct parm_table[] = {
                .label          = "print command",
                .type           = P_STRING,
                .p_class        = P_LOCAL,
-               .offset         = LOCAL_VAR(printcommand),
+               .offset         = LOCAL_VAR(print_command),
                .special        = NULL,
                .enum_list      = NULL,
                .flags          = FLAG_ADVANCED | FLAG_PRINT | FLAG_GLOBAL,
index 6833718fdd2b28b293b3af49e9781cbf6e2fc005..4c188fba9f50c431506c59692ace95e5a877c566 100644 (file)
@@ -158,7 +158,7 @@ static struct loadparm_service sDefault =
        .root_preexec = NULL,
        .root_postexec = NULL,
        .cups_options = NULL,
-       .printcommand = NULL,
+       .print_command = NULL,
        .lpq_command = NULL,
        .lprm_command = NULL,
        .lppause_command = NULL,
@@ -383,14 +383,14 @@ static void init_printer_values(struct loadparm_service *pService)
                case PRINT_LPROS2:
                        string_set(&pService->lpq_command, "lpq -P'%p'");
                        string_set(&pService->lprm_command, "lprm -P'%p' %j");
-                       string_set(&pService->printcommand, "lpr -r -P'%p' %s");
+                       string_set(&pService->print_command, "lpr -r -P'%p' %s");
                        break;
 
                case PRINT_LPRNG:
                case PRINT_PLP:
                        string_set(&pService->lpq_command, "lpq -P'%p'");
                        string_set(&pService->lprm_command, "lprm -P'%p' %j");
-                       string_set(&pService->printcommand, "lpr -r -P'%p' %s");
+                       string_set(&pService->print_command, "lpr -r -P'%p' %s");
                        string_set(&pService->queuepausecommand, "lpc stop '%p'");
                        string_set(&pService->queueresumecommand, "lpc start '%p'");
                        string_set(&pService->lppause_command, "lpc hold '%p' %j");
@@ -403,7 +403,7 @@ static void init_printer_values(struct loadparm_service *pService)
                           name only.  This is used by cups_queue_get() */
                        string_set(&pService->lpq_command, "%p");
                        string_set(&pService->lprm_command, "");
-                       string_set(&pService->printcommand, "");
+                       string_set(&pService->print_command, "");
                        string_set(&pService->lppause_command, "");
                        string_set(&pService->lpresume_command, "");
                        string_set(&pService->queuepausecommand, "");
@@ -414,7 +414,7 @@ static void init_printer_values(struct loadparm_service *pService)
                case PRINT_HPUX:
                        string_set(&pService->lpq_command, "lpstat -o%p");
                        string_set(&pService->lprm_command, "cancel %p-%j");
-                       string_set(&pService->printcommand, "lp -c -d%p %s; rm %s");
+                       string_set(&pService->print_command, "lp -c -d%p %s; rm %s");
                        string_set(&pService->queuepausecommand, "disable %p");
                        string_set(&pService->queueresumecommand, "enable %p");
 #ifndef HPUX
@@ -426,7 +426,7 @@ static void init_printer_values(struct loadparm_service *pService)
                case PRINT_QNX:
                        string_set(&pService->lpq_command, "lpq -P%p");
                        string_set(&pService->lprm_command, "lprm -P%p %j");
-                       string_set(&pService->printcommand, "lp -r -P%p %s");
+                       string_set(&pService->print_command, "lp -r -P%p %s");
                        break;
 
 #if defined(DEVELOPER) || defined(ENABLE_SELFTEST)
@@ -447,7 +447,7 @@ static void init_printer_values(struct loadparm_service *pService)
 
                tmp = talloc_asprintf(tmp_ctx, "vlp %s print %%p %%s",
                                      tdbfile);
-               string_set(&pService->printcommand,
+               string_set(&pService->print_command,
                           tmp ? tmp : "vlp print %p %s");
 
                tmp = talloc_asprintf(tmp_ctx, "vlp %s lpq %%p",
index 681bc551806a8f43f29e888dbde05f09082a07ea..72bfa2b9783b17efcc71bbf52579dd0cceabc87c 100644 (file)
@@ -255,7 +255,7 @@ static int generic_job_submit(int snum, struct printjob *pjob,
 
        /* send it to the system spooler */
        ret = print_run_command(snum, lp_printername(talloc_tos(), snum), True,
-                       lp_printcommand(talloc_tos(), snum), NULL,
+                       lp_print_command(talloc_tos(), snum), NULL,
                        "%s", p,
                        "%J", jobname,
                        "%f", p,
index bf024c6bab07ddd8a687be754d85d5b62c8c975d..afca8f83c46ce260641bf17d3bebddcb943fcfed 100644 (file)
@@ -415,7 +415,7 @@ static void do_per_share_checks(int s)
                        "excludes octal 010 (S_IXGRP).\n\n",
                        lp_servicename(talloc_tos(), s));
        }
-       if (lp_printing(s) == PRINT_CUPS && *(lp_printcommand(talloc_tos(), s)) != '\0') {
+       if (lp_printing(s) == PRINT_CUPS && *(lp_print_command(talloc_tos(), s)) != '\0') {
                fprintf(stderr,
                        "Warning: Service %s defines a print command, but "
                        "parameter is ignored when using CUPS libraries.\n\n",