Remove NOPROTO definitions and error code comments.
[openssl.git] / crypto / des / read_pwd.c
index 45f66b5da1aabc486a5e5f648e63c6697536faa3..24e814ec76e4994e51ed1ec5c6eafb142383d483 100644 (file)
@@ -56,7 +56,7 @@
  * [including the GNU Public Licence.]
  */
 
-#if !defined(MSDOS) && !defined(VMS)
+#if !defined(MSDOS) && !defined(VMS) && !defined(WIN32)
 #include <unistd.h>
 /* If unistd.h defines _POSIX_VERSION, we conclude that we
  * are on a POSIX system and have sigaction and termios. */
@@ -169,7 +169,6 @@ struct IOSB {
 #define NX509_SIG 32
 #endif
 
-#ifndef NOPROTO
 static void read_till_nl(FILE *);
 static void recsig(int);
 static void pushsig(void);
@@ -177,16 +176,6 @@ static void popsig(void);
 #if defined(MSDOS) && !defined(WIN16)
 static int noecho_fgets(char *buf, int size, FILE *tty);
 #endif
-#else
-static void read_till_nl();
-static void recsig();
-static void pushsig();
-static void popsig();
-#if defined(MSDOS) && !defined(WIN16)
-static int noecho_fgets();
-#endif
-#endif
-
 #ifdef SIGACTION
  static struct sigaction savsig[NX509_SIG];
 #else
@@ -198,11 +187,8 @@ static int noecho_fgets();
 #endif
 static jmp_buf save;
 
-int des_read_pw_string(buf, length, prompt, verify)
-char *buf;
-int length;
-const char *prompt;
-int verify;
+int des_read_pw_string(char *buf, int length, const char *prompt,
+            int verify)
        {
        char buff[BUFSIZ];
        int ret;
@@ -214,8 +200,7 @@ int verify;
 
 #ifndef WIN16
 
-static void read_till_nl(in)
-FILE *in;
+static void read_till_nl(FILE *in)
        {
 #define SIZE 4
        char buf[SIZE+1];
@@ -227,12 +212,8 @@ FILE *in;
 
 
 /* return 0 if ok, 1 (or -1) otherwise */
-int des_read_pw(buf, buff, size, prompt, verify)
-char *buf;
-char *buff;
-int size;
-const char *prompt;
-int verify;
+int des_read_pw(char *buf, char *buff, int size, const char *prompt,
+            int verify)
        {
 #ifdef VMS
        struct IOSB iosb;
@@ -382,12 +363,7 @@ error:
 
 #else /* WIN16 */
 
-int des_read_pw(buf, buff, size, prompt, verify)
-char *buf;
-char *buff;
-int size;
-char *prompt;
-int verify;
+int des_read_pw(char *buf, char *buff, int size, char *prompt, int verify)
        { 
        memset(buf,0,size);
        memset(buff,0,size);
@@ -396,7 +372,7 @@ int verify;
 
 #endif
 
-static void pushsig()
+static void pushsig(void)
        {
        int i;
 #ifdef SIGACTION
@@ -428,7 +404,7 @@ static void pushsig()
 #endif
        }
 
-static void popsig()
+static void popsig(void)
        {
        int i;
 
@@ -450,8 +426,7 @@ static void popsig()
                }
        }
 
-static void recsig(i)
-int i;
+static void recsig(int i)
        {
        longjmp(save,1);
 #ifdef LINT
@@ -460,10 +435,7 @@ int i;
        }
 
 #if defined(MSDOS) && !defined(WIN16)
-static int noecho_fgets(buf,size,tty)
-char *buf;
-int size;
-FILE *tty;
+static int noecho_fgets(char *buf, int size, FILE *tty)
        {
        int i;
        char *p;