]> git.ipfire.org Git - thirdparty/HylaFAX.git/commitdiff
Cast strtol to int to get rid of warnings.
authorTim Rice <tim@multitalents.net>
Fri, 18 Apr 2003 21:03:40 +0000 (21:03 +0000)
committerTim Rice <tim@multitalents.net>
Fri, 18 Apr 2003 21:03:40 +0000 (21:03 +0000)
"../src/faxd/ClassModem.c++", line 1092: warning:  long  assigned to  int
"../src/faxd/ClassModem.c++", line 1118: warning:  long  assigned to  int

faxd/ClassModem.c++

index 3d900fbce6e6745b24d0581a058324da2cf8cae7..ada5f2d37cfa2faaf0b70d068ba604d73749d758 100644 (file)
@@ -1089,7 +1089,7 @@ ClassModem::vparseRange(const char* cp, int nargs ... )
            if (conf.class2UseHex) {                    // read as hex
                if (isxdigit(cp[0])) {
                    char *endp;
-                   v = strtol(cp, &endp, 16);
+                   v = (int) strtol(cp, &endp, 16);
                    cp = endp;
                } else {
                    v = -1;                             // XXX skip item below
@@ -1115,7 +1115,7 @@ ClassModem::vparseRange(const char* cp, int nargs ... )
                        goto done;
                    }
                    char *endp;
-                   r = strtol(cp, &endp, 16);
+                   r = (int) strtol(cp, &endp, 16);
                    cp = endp;
                } else {                                // assume decimal
                    if (!isdigit(cp[0])) {