Changeset 19c0c55


Ignore:
Timestamp:
Mar 29, 2009, 3:41:03 PM (15 years ago)
Author:
James M. Kretchmar <kretch@mit.edu>
Branches:
owl
Children:
488ebf6
Parents:
2b23a36a
Message:
remove unnecessary putenv and unnecessary sprintf
File:
1 edited

Legend:

Unmodified
Added
Removed
  • owl.c

    r395b32e r19c0c55  
    5959  int newmsgs, nexttimediff;
    6060  struct sigaction sigact;
    61   char *configfile, *tty, *perlout, *perlerr, **argvsave, buff[LINE], startupmsg[LINE];
     61  char *configfile, *tty, *perlout, *perlerr, **argvsave;
    6262  owl_filter *f;
    6363  owl_style *s;
     
    6666  char *dir;
    6767  struct termios tio;
    68 #if OWL_STDERR_REDIR
    69   int newstderr;
    70 #endif
    7168
    7269  argcsave=argc;
     
    153150  /* screen init */
    154151  if (!getenv("TERMINFO")) {
    155     sprintf(buff, "TERMINFO=%s", TERMINFO);
    156     putenv(buff);
    157     owl_function_debugmsg("startup: setting TERMINFO to %s", TERMINFO);
     152    owl_function_debugmsg("startup: found TERMINFO unset in environment");
    158153  } else {
    159     owl_function_debugmsg("startup: leaving TERMINFO as %s from envrionment", getenv("TERMINFO"));
     154    owl_function_debugmsg("startup: found TERMINFO is %s from environment", getenv("TERMINFO"));
    160155  }
    161156  initscr();
     
    358353  /* welcome message */
    359354  owl_function_debugmsg("startup: creating splash message");
    360   strcpy(startupmsg, "-----------------------------------------------------------------------\n");
    361   sprintf(buff,      "Welcome to Owl version %s.  Press 'h' for on-line help. \n", OWL_VERSION_STRING);
    362   strcat(startupmsg, buff);
    363   strcat(startupmsg, "                                                                       \n");
    364   strcat(startupmsg, "If you would like to receive release announcements about Owl you can   \n");
    365   strcat(startupmsg, "join the owl-users mailing list at http://www.ktools.org/              \n");
    366   strcat(startupmsg, "                                                                 ^ ^   \n");
    367   strcat(startupmsg, "                                                                 OvO   \n");
    368   strcat(startupmsg, "Please report any bugs or suggestions to bug-owl@ktools.org     (   )  \n");
    369   strcat(startupmsg, "-----------------------------------------------------------------m-m---\n");
    370   owl_function_adminmsg("", startupmsg);
     355  owl_function_adminmsg("",
     356                        "-----------------------------------------------------------------------\n"
     357                        "Welcome to Owl version " OWL_VERSION_STRING ".  Press 'h' for on-line help. \n"
     358                        "                                                                       \n"
     359                        "If you would like to receive release announcements about Owl you can   \n"
     360                        "join the owl-users mailing list at http://www.ktools.org/              \n"
     361                        "                                                                 ^ ^   \n"
     362                        "                                                                 OvO   \n"
     363                        "Please report any bugs or suggestions to bug-owl@ktools.org     (   )  \n"
     364                        "-----------------------------------------------------------------m-m---\n"
     365                        );
    371366  sepbar(NULL);
    372367
Note: See TracChangeset for help on using the changeset viewer.