mirror of
https://github.com/libssh2/libssh2.git
synced 2025-07-31 00:03:08 +03:00
tidy-up: bump casts from int to long for large C99 types in printfs
Cast large integer types to avoid dealing with printf masks for
`size_t` and other C99 types. Some of existing code used `int`
for this, bump them to `long`.
Ref: afa6b86560
#1257
Closes #1264
This commit is contained in:
@ -241,8 +241,8 @@ int main(int argc, char *argv[])
|
||||
else {
|
||||
if(nread != LIBSSH2_ERROR_EAGAIN)
|
||||
/* no need to output this for the EAGAIN case */
|
||||
fprintf(stderr, "libssh2_channel_read returned %d\n",
|
||||
(int)nread);
|
||||
fprintf(stderr, "libssh2_channel_read returned %ld\n",
|
||||
(long)nread);
|
||||
}
|
||||
}
|
||||
while(nread > 0);
|
||||
@ -269,8 +269,8 @@ int main(int argc, char *argv[])
|
||||
fprintf(stderr, "\nGot signal: %s\n", exitsignal);
|
||||
}
|
||||
else {
|
||||
fprintf(stderr, "\nEXIT: %d bytecount: %d\n",
|
||||
exitcode, (int)bytecount);
|
||||
fprintf(stderr, "\nEXIT: %d bytecount: %ld\n",
|
||||
exitcode, (long)bytecount);
|
||||
}
|
||||
|
||||
libssh2_channel_free(channel);
|
||||
|
Reference in New Issue
Block a user