]> git.ipfire.org Git - thirdparty/cups.git/commitdiff
Fix bug in argument processing.
authorMichael Sweet <michael.r.sweet@gmail.com>
Tue, 6 Jun 2017 13:16:14 +0000 (09:16 -0400)
committerMichael Sweet <michael.r.sweet@gmail.com>
Tue, 6 Jun 2017 13:16:14 +0000 (09:16 -0400)
systemv/lpstat.c

index a3474a6d7daa3a20b66e396a2391b008a756d811..5d3654dbfa1e0e28c44250d129de67999429b265 100644 (file)
@@ -77,7 +77,7 @@ main(int  argc,                               /* I - Number of command-line arguments */
     {
       for (opt = argv[i] + 1; *opt; opt ++)
       {
-       switch (argv[i][1])
+       switch (*opt)
        {
          case 'D' : /* Show description */
              long_status = 1;
@@ -257,7 +257,6 @@ main(int  argc,                             /* I - Number of command-line arguments */
 
                 cupsFreeDests(num_temp, temp);
               }
-
               break;
 
          case 'f' : /* Show forms */