]> diplodocus.org Git - nmh/blobdiff - sbr/m_atoi.c
mhlsbr.c: Use variable for strncpy(3)'s size, not sizeof.
[nmh] / sbr / m_atoi.c
index f05271f7102d0e0f09b0009bdea263f5433be37d..74da5c0d9a147d572a143624bad71f813b407f6d 100644 (file)
@@ -1,6 +1,4 @@
-
-/*
- * m_atoi.c -- Parse a string representation of a message number, and
+/* m_atoi.c -- Parse a string representation of a message number, and
  *          -- return the numeric value of the message.  If the string
  *          -- contains any non-digit characters, then return 0.
  *
@@ -9,7 +7,8 @@
  * complete copyright information.
  */
 
-#include <h/mh.h>
+#include "h/mh.h"
+#include "m_atoi.h"
 
 
 int
@@ -19,11 +18,7 @@ m_atoi (char *str)
     char *cp;
 
     for (i = 0, cp = str; *cp; cp++) {
-#ifdef LOCALE
        if (!isdigit((unsigned char) *cp))
-#else
-       if (*cp < '0' || *cp > '9')
-#endif
            return 0;
 
        i *= 10;