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

@@ -18,10 +18,11 @@
  * information: Portions Copyright [yyyy] [name of copyright owner]
  *
  * CDDL HEADER END
  */
 /*
+ * Copyright 2017 Gary Mills
  * Copyright 1997 Sun Microsystems, Inc.  All rights reserved.
  * Use is subject to license terms.
  */
 
 /*      Copyright (c) 1983, 1984, 1985, 1986, 1987, 1988, 1989 AT&T     */

@@ -35,12 +36,10 @@
  * University Acknowledgment- Portions of this document are derived from
  * software developed by the University of California, Berkeley, and its
  * contributors.
  */
 
-#pragma ident   "%Z%%M% %I%     %E% SMI"
-
 #include "talk.h"
 #include "ctl.h"
 #include <locale.h>
 #include <pwd.h>
 #include <sys/systeminfo.h>

@@ -63,11 +62,10 @@
         char hostname[HOST_NAME_LENGTH + 1];
         char *rem_name;
         char *my_name;
         char *my_machine_name;
         char *rem_machine_name;
-        char *my_tty;
         char *rem_tty;
         char *ptr;
         int name_length;
 
         if (argc < 2) {

@@ -100,12 +98,10 @@
 
         name_length = HOST_NAME_LENGTH;
         (void) sysinfo(SI_HOSTNAME, hostname, name_length);
         my_machine_name = hostname;
 
-        my_tty = strrchr(ttyname(0), '/') + 1;
-
         /*
          * check for, and strip out, the machine name of the target
          */
 
         for (ptr = argv[1]; *ptr != '\0' &&