Print this page
8485 Remove set but unused variables in usr/src/cmd

Split Close
Expand all
Collapse all
          --- old/usr/src/cmd/print/bsd-sysv-commands/disable.c
          +++ new/usr/src/cmd/print/bsd-sysv-commands/disable.c
↓ open down ↓ 13 lines elided ↑ open up ↑
  14   14   * When distributing Covered Code, include this CDDL HEADER in each
  15   15   * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  16   16   * If applicable, add the following below this CDDL HEADER, with the
  17   17   * fields enclosed by brackets "[]" replaced with your own identifying
  18   18   * information: Portions Copyright [yyyy] [name of copyright owner]
  19   19   *
  20   20   * CDDL HEADER END
  21   21   */
  22   22  
  23   23  /*
       24 + * Copyright 2017 Gary Mills
  24   25   * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  25   26   * Use is subject to license terms.
  26   27   *
  27   28   */
  28   29  
  29   30  /* $Id: disable.c 146 2006-03-24 00:26:54Z njacobs $ */
  30   31  
  31   32  
  32   33  #include <stdio.h>
  33   34  #include <stdlib.h>
↓ open down ↓ 51 lines elided ↑ open up ↑
  85   86  }
  86   87  
  87   88  int
  88   89  main(int ac, char *av[])
  89   90  {
  90   91          papi_status_t status;
  91   92          papi_service_t svc = NULL;
  92   93          papi_encryption_t encryption = PAPI_ENCRYPT_NEVER;
  93   94          int exit_status = 0;
  94   95          int cancel = 0;
  95      -        int pending = 0;        /* not implemented */
  96   96          char *reason = NULL;
  97   97          int c;
  98   98  
  99   99          (void) setlocale(LC_ALL, "");
 100  100          (void) textdomain("SUNW_OST_OSCMD");
 101  101  
 102  102          while ((c = getopt(ac, av, "EcWr:")) != EOF)
 103  103                  switch (c) {
 104  104                  case 'c':       /* cancel active job first */
 105  105                          cancel = 1;
 106  106                          break;
 107  107                  case 'W':       /* wait for active request, not implemented */
 108      -                        pending = 1;
 109  108                          break;
 110  109                  case 'r':       /* reason */
 111  110                          reason = optarg;
 112  111                          break;
 113  112                  case 'E':
 114  113                          encryption = PAPI_ENCRYPT_NEVER;
 115  114                          break;
 116  115                  default:
 117  116                          usage(av[0]);
 118  117                  }
↓ open down ↓ 45 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX