Fixing is_disk() which mistakes devices with name longer than 20 chars for partitions.

Associated with previous vmstat -d enhancement commit.
This commit is contained in:
Jan Rybar 2016-08-04 11:25:19 +02:00
parent b4fdb27a05
commit c63a5a4af0

View File

@ -938,7 +938,7 @@ unsigned int getpartitions_num(struct disk_stat *disks, int ndisks){
/////////////////////////////////////////////////////////////////////////////
static int is_disk(char *dev)
{
char syspath[32];
char syspath[64];
char *slash;
while ((slash = strchr(dev, '/')))