lsblk: use ssize_t for readlink() return code

Signed-off-by: Karel Zak <kzak@redhat.com>
This commit is contained in:
Karel Zak 2011-03-11 10:49:08 +01:00
parent 18eac5bad9
commit eb9a65bb54
2 changed files with 2 additions and 2 deletions

View File

@ -861,7 +861,7 @@ static int process_one_device(char *devname)
/*
* Parititioned, read sysfs name of the device
*/
size_t len;
ssize_t len;
char path[PATH_MAX], *diskname, *name;
snprintf(path, sizeof(path), "/sys/dev/block/%d:%d",

View File

@ -184,7 +184,7 @@ static void
readlink_to_namei(struct namei *nm, const char *path)
{
char sym[PATH_MAX];
size_t sz;
ssize_t sz;
sz = readlink(path, sym, sizeof(sym));
if (sz < 1)