mirror of https://github.com/wolfSSL/wolfssh.git
Reverted strtol to atoi
parent
52a1e13470
commit
b95d43fd1c
|
@ -894,7 +894,7 @@ static int GetScpFileSize(WOLFSSH* ssh, byte* buf, word32 bufSz,
|
||||||
if (ret == WS_SUCCESS) {
|
if (ret == WS_SUCCESS) {
|
||||||
/* replace space with newline for atoi */
|
/* replace space with newline for atoi */
|
||||||
buf[spaceIdx] = '\n';
|
buf[spaceIdx] = '\n';
|
||||||
ssh->scpFileSz = strtol((char *)(buf + idx), NULL, 10);
|
ssh->scpFileSz = atoi((char *)(buf + idx));
|
||||||
|
|
||||||
/* restore space, increment idx to space */
|
/* restore space, increment idx to space */
|
||||||
buf[spaceIdx] = ' ';
|
buf[spaceIdx] = ' ';
|
||||||
|
@ -1000,7 +1000,7 @@ static int GetScpTimestamp(WOLFSSH* ssh, byte* buf, word32 bufSz,
|
||||||
if (ret == WS_SUCCESS) {
|
if (ret == WS_SUCCESS) {
|
||||||
/* replace space with newline for atoi */
|
/* replace space with newline for atoi */
|
||||||
buf[spaceIdx] = '\n';
|
buf[spaceIdx] = '\n';
|
||||||
ssh->scpMTime = strtol((char*)(buf + idx), NULL, 10);
|
ssh->scpMTime = atoi((char*)(buf + idx));
|
||||||
|
|
||||||
/* restore space, increment idx past it */
|
/* restore space, increment idx past it */
|
||||||
buf[spaceIdx] = ' ';
|
buf[spaceIdx] = ' ';
|
||||||
|
@ -1032,7 +1032,7 @@ static int GetScpTimestamp(WOLFSSH* ssh, byte* buf, word32 bufSz,
|
||||||
if (ret == WS_SUCCESS) {
|
if (ret == WS_SUCCESS) {
|
||||||
/* replace space with newline for atoi */
|
/* replace space with newline for atoi */
|
||||||
buf[spaceIdx] = '\n';
|
buf[spaceIdx] = '\n';
|
||||||
ssh->scpATime = strtol((char*)(buf + idx), NULL, 10);
|
ssh->scpATime = atoi((char*)(buf + idx));
|
||||||
|
|
||||||
/* restore space, increment idx past it */
|
/* restore space, increment idx past it */
|
||||||
buf[spaceIdx] = ' ';
|
buf[spaceIdx] = ' ';
|
||||||
|
|
Loading…
Reference in New Issue