diff options
author | Eric S. Raymond <esr@thyrsus.com> | 1998-10-26 19:57:45 +0000 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 1998-10-26 19:57:45 +0000 |
commit | 836bbce0c428581f40d13d8c3d27d1c7adc31ccb (patch) | |
tree | 3d03fdd0b5bdda66ef27bf852cac646968968882 /getpass.c | |
parent | bcc60aebf68fd7839c708a623048636a03f05043 (diff) | |
download | fetchmail-836bbce0c428581f40d13d8c3d27d1c7adc31ccb.tar.gz fetchmail-836bbce0c428581f40d13d8c3d27d1c7adc31ccb.tar.bz2 fetchmail-836bbce0c428581f40d13d8c3d27d1c7adc31ccb.zip |
Jonathan T. Agnew's massive code cleanup.
svn path=/trunk/; revision=2137
Diffstat (limited to 'getpass.c')
-rw-r--r-- | getpass.c | 22 |
1 files changed, 11 insertions, 11 deletions
@@ -54,10 +54,10 @@ static int ttyfd; #endif #endif -void static save_tty_state(); -void static disable_tty_echo(); -void static restore_tty_state(); -static RETSIGTYPE sigint_handler(); +void static save_tty_state(void); +void static disable_tty_echo(void); +void static restore_tty_state(void); +static RETSIGTYPE sigint_handler(int); char *getpassword(prompt) char *prompt; @@ -72,11 +72,11 @@ char *prompt; #endif #else register char *p; - register c; + register int c; FILE *fi; static char pbuf[INPUT_BUF_SIZE]; - RETSIGTYPE (*sig)() = 0; /* initialization pacifies -Wall */ - RETSIGTYPE sigint_handler(); + RETSIGTYPE (*sig)(int) = 0; /* initialization pacifies -Wall */ + RETSIGTYPE sigint_handler(int); int istty = isatty(0); @@ -136,7 +136,7 @@ char *prompt; #endif /* !(defined(HAVE_TCSETATTR) || ... */ } -static void save_tty_state () +static void save_tty_state (void) { #if defined(HAVE_TCSETATTR) tcgetattr(ttyfd, &termb); @@ -152,7 +152,7 @@ static void save_tty_state () #endif } -static void disable_tty_echo() +static void disable_tty_echo(void) { /* turn off echo on the tty */ #if defined(HAVE_TCSETATTR) @@ -169,7 +169,7 @@ static void disable_tty_echo() #endif } -static void restore_tty_state() +static void restore_tty_state(void) { /* restore previous tty echo state */ #if defined(HAVE_TCSETATTR) @@ -186,7 +186,7 @@ static void restore_tty_state() #endif } -static RETSIGTYPE sigint_handler() +static RETSIGTYPE sigint_handler(int signum) { restore_tty_state(); error(1, 0, "\nCaught signal... bailing out."); |