diff options
Diffstat (limited to 'net/tftp.c')
-rw-r--r-- | net/tftp.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/net/tftp.c b/net/tftp.c index 00ab7ca0b3..5baf528f4e 100644 --- a/net/tftp.c +++ b/net/tftp.c @@ -554,8 +554,7 @@ static void tftp_handler(uchar *pkt, unsigned dest, struct in_addr sip, for (i = 0; i+8 < len; i++) { if (strcasecmp((char *)pkt + i, "blksize") == 0) { tftp_block_size = (unsigned short) - simple_strtoul((char *)pkt + i + 8, - NULL, 10); + dectoul((char *)pkt + i + 8, NULL); debug("Blocksize oack: %s, %d\n", (char *)pkt + i + 8, tftp_block_size); if (tftp_block_size > tftp_block_size_option) { @@ -566,8 +565,7 @@ static void tftp_handler(uchar *pkt, unsigned dest, struct in_addr sip, } if (strcasecmp((char *)pkt + i, "timeout") == 0) { timeout_val_rcvd = (unsigned short) - simple_strtoul((char *)pkt + i + 8, - NULL, 10); + dectoul((char *)pkt + i + 8, NULL); debug("Timeout oack: %s, %d\n", (char *)pkt + i + 8, timeout_val_rcvd); if (timeout_val_rcvd != (timeout_ms / 1000)) { @@ -578,16 +576,15 @@ static void tftp_handler(uchar *pkt, unsigned dest, struct in_addr sip, } #ifdef CONFIG_TFTP_TSIZE if (strcasecmp((char *)pkt + i, "tsize") == 0) { - tftp_tsize = simple_strtoul((char *)pkt + i + 6, - NULL, 10); + tftp_tsize = dectoul((char *)pkt + i + 6, + NULL); debug("size = %s, %d\n", (char *)pkt + i + 6, tftp_tsize); } #endif if (strcasecmp((char *)pkt + i, "windowsize") == 0) { tftp_windowsize = - simple_strtoul((char *)pkt + i + 11, - NULL, 10); + dectoul((char *)pkt + i + 11, NULL); debug("windowsize = %s, %d\n", (char *)pkt + i + 11, tftp_windowsize); } |