diff options
author | jacobs <none@none> | 2008-05-27 14:53:29 -0700 |
---|---|---|
committer | jacobs <none@none> | 2008-05-27 14:53:29 -0700 |
commit | 43b9c05035ac59f7f7a8e7827598db5a15f30ed3 (patch) | |
tree | 56acec6855e6d9ed3f7770900436aec472d430eb /usr/src/cmd/print/bsd-sysv-commands/in.lpd.c | |
parent | cdfc78ad277d82b1080e7c86213063d1b73e7789 (diff) | |
download | illumos-joyent-43b9c05035ac59f7f7a8e7827598db5a15f30ed3.tar.gz |
6698648 127127/127128-11 break lp -P
6698649 127127/127128-11 break lp -H hold
6698650 127127/127128-11 break lp -q
6704910 S10_u5 printing not properly parsing options
6705311 Can not give privilege to change properties for snmp
Diffstat (limited to 'usr/src/cmd/print/bsd-sysv-commands/in.lpd.c')
-rw-r--r-- | usr/src/cmd/print/bsd-sysv-commands/in.lpd.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/usr/src/cmd/print/bsd-sysv-commands/in.lpd.c b/usr/src/cmd/print/bsd-sysv-commands/in.lpd.c index 7782ee9a36..6a012adcb1 100644 --- a/usr/src/cmd/print/bsd-sysv-commands/in.lpd.c +++ b/usr/src/cmd/print/bsd-sysv-commands/in.lpd.c @@ -20,7 +20,7 @@ */ /* - * Copyright 2006 Sun Microsystems, Inc. All rights reserved. + * Copyright 2008 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. * */ @@ -308,14 +308,10 @@ parse_cf(papi_service_t svc, char *cf, char **files) papiAttributeListAddString(&list, PAPI_ATTR_EXCL, "job-hold-until", "indefinite"); - else if (strcasecmp(entry, "release") == 0) + else if (strcasecmp(entry, "immediate") == 0) papiAttributeListAddString(&list, PAPI_ATTR_EXCL, "job-hold-until", "no-hold"); - else if (strcasecmp(entry, "immediate") == 0) - papiAttributeListAddInteger(&list, - PAPI_ATTR_EXCL, - "job-priority", 100); else papiAttributeListAddString(&list, PAPI_ATTR_EXCL, @@ -325,19 +321,23 @@ parse_cf(papi_service_t svc, char *cf, char **files) papiAttributeListAddBoolean(&list, PAPI_ATTR_EXCL, "rfc-1179-mail", 1); break; - case 'P': /* Solaris page list */ - papiAttributeListAddString(&list, - PAPI_ATTR_EXCL, - "page-ranges", ++entry); + case 'P': { /* Solaris page list */ + char buf[BUFSIZ]; + + snprintf(buf, sizeof (buf), "page-ranges=%s", + ++entry); + papiAttributeListFromString(&list, + PAPI_ATTR_EXCL, buf); + } break; case 'q': { /* Solaris priority */ int i = atoi(optarg); - i = 99 * (39 - i) / 39 + 1; + i = 100 - (i * 2.5); if ((i < 1) || (i > 100)) i = 50; papiAttributeListAddInteger(&list, - PAPI_ATTR_EXCL, "priority", i); + PAPI_ATTR_EXCL, "job-priority", i); } break; case 'S': /* Solaris character set */ |