[pacman-dev] CVS update of pacman-lib/src/pacman (log.c pacman.c util.c)
Date: Wednesday, January 24, 2007 @ 11:57:19 Author: aaron Path: /home/cvs-pacman/pacman-lib/src/pacman Modified: log.c (1.24 -> 1.25) pacman.c (1.82 -> 1.83) util.c (1.22 -> 1.23) Cleanup 'neednl' usage - make it static ----------+ log.c | 2 +- pacman.c | 18 +++--------------- util.c | 1 - 3 files changed, 4 insertions(+), 17 deletions(-) Index: pacman-lib/src/pacman/log.c diff -u pacman-lib/src/pacman/log.c:1.24 pacman-lib/src/pacman/log.c:1.25 --- pacman-lib/src/pacman/log.c:1.24 Wed Jan 24 03:51:51 2007 +++ pacman-lib/src/pacman/log.c Wed Jan 24 11:57:19 2007 @@ -37,7 +37,7 @@ extern config_t *config; -int neednl = 0; /* for cleaner message output */ +static int neednl = 0; /* for cleaner message output */ static int needpad = 0; /* pad blanks to terminal width */ /* simple helper for needpad */ Index: pacman-lib/src/pacman/pacman.c diff -u pacman-lib/src/pacman/pacman.c:1.82 pacman-lib/src/pacman/pacman.c:1.83 --- pacman-lib/src/pacman/pacman.c:1.82 Fri Jan 19 04:28:46 2007 +++ pacman-lib/src/pacman/pacman.c Wed Jan 24 11:57:19 2007 @@ -78,8 +78,6 @@ /* list of targets specified on command line */ static alpm_list_t *pm_targets; -extern int neednl; - /* Display usage/syntax for the specified operation. * op: the operation code requested * myname: basename(argv[0]) @@ -197,14 +195,8 @@ FREELIST(pm_targets); FREECONF(config); - if(neednl) { - putchar('\n'); - } - - /* restore the cursor - printf("\033[?25h\033[?0c"); - fflush(stdout); - */ + /* This fixes up any missing newlines (neednl) */ + MSG(NL, ""); exit(signum); } @@ -407,10 +399,6 @@ signal(SIGTERM, cleanup); signal(SIGSEGV, cleanup); - /* hide the cursor, prevent flicker during fancy graphics - printf("\033[?25l\033[?1c"); - */ - /* i18n init */ lang=getenv("LC_ALL"); if(lang==NULL || lang[0]=='\0') @@ -419,7 +407,7 @@ lang=getenv("LANG"); setlocale(LC_ALL, lang); - // workaround for tr_TR + /* workaround for tr_TR */ if(lang && !strcmp(lang, "tr_TR")) setlocale(LC_CTYPE, "C"); bindtextdomain("pacman", "/usr/share/locale"); Index: pacman-lib/src/pacman/util.c diff -u pacman-lib/src/pacman/util.c:1.22 pacman-lib/src/pacman/util.c:1.23 --- pacman-lib/src/pacman/util.c:1.22 Fri Jan 19 04:28:47 2007 +++ pacman-lib/src/pacman/util.c Wed Jan 24 11:57:19 2007 @@ -49,7 +49,6 @@ #include "log.h" extern config_t *config; -extern int neednl; /* gets the current screen column width */ unsigned int getcols()
participants (1)
-
Aaron Griffin