diff options
author | Christian Göttsche <cgzones@googlemail.com> | 2020-11-24 17:40:00 +0100 |
---|---|---|
committer | BenBE <BenBE@geshi.org> | 2020-12-05 19:58:32 +0100 |
commit | f61e74a4afb12952e9be136729bbc0cb8e977868 (patch) | |
tree | dfffa9ade7aa363cf3a6bc4d78833520d553ec11 | |
parent | 8029e9af04e6cd812383c392b791e6c4fd50b26d (diff) |
Resolve conversion from ssize_t to int for readlink return value
-rw-r--r-- | Compat.c | 10 | ||||
-rw-r--r-- | Compat.h | 10 | ||||
-rw-r--r-- | linux/Platform.c | 2 |
3 files changed, 11 insertions, 11 deletions
@@ -94,11 +94,11 @@ int Compat_openat(const char* dirpath, #endif /* !HAVE_OPENAT */ -int Compat_readlinkat(int dirfd, - const char* dirpath, - const char* pathname, - char* buf, - size_t bufsize) { +ssize_t Compat_readlinkat(int dirfd, + const char* dirpath, + const char* pathname, + char* buf, + size_t bufsize) { #ifdef HAVE_READLINKAT @@ -50,10 +50,10 @@ int Compat_openat(openat_arg_t dirpath, const char* pathname, int flags); #endif /* HAVE_OPENAT */ -int Compat_readlinkat(int dirfd, - const char* dirpath, - const char* pathname, - char* buf, - size_t bufsize); +ssize_t Compat_readlinkat(int dirfd, + const char* dirpath, + const char* pathname, + char* buf, + size_t bufsize); #endif /* HEADER_Compat */ diff --git a/linux/Platform.c b/linux/Platform.c index 833044b1..dc917459 100644 --- a/linux/Platform.c +++ b/linux/Platform.c @@ -371,7 +371,7 @@ char* Platform_getInodeFilename(pid_t pid, ino_t inode) { struct stat sb; struct dirent *de; DIR *dirp; - size_t len; + ssize_t len; int fd; char path[PATH_MAX]; |