From d1b139f8e205faac5adfb4d032f8f899177e18f2 Mon Sep 17 00:00:00 2001 From: Phil Date: Sat, 6 Dec 2008 19:10:27 +0000 Subject: [PATCH] since DEV_NAME() is used when calling, this check is needless git-svn-id: https://conky.svn.sourceforge.net/svnroot/conky/trunk/conky1@1274 7f574dfc-610e-0410-a909-a81674777703 --- ChangeLog | 3 +++ src/diskio.c | 8 ++------ 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/ChangeLog b/ChangeLog index 2a0d0304..344ca7c3 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ # $Id$ +2008-12-06 + * Removed duplicate sanity check for diskio + 2008-11-30 * Added runtime debugging output diff --git a/src/diskio.c b/src/diskio.c index 4d3a2182..515f3230 100644 --- a/src/diskio.c +++ b/src/diskio.c @@ -86,12 +86,8 @@ struct diskio_stat *prepare_diskio_stat(const char *s) free(new->dev); new->dev = 0; } - if (strncmp(s, "/dev/", 5) == 0) { - // supplied a /dev/device arg, so cut off the /dev part - new->dev = strndup(s + 5, text_buffer_size); - } else { - new->dev = strndup(s, text_buffer_size); - } + new->dev = strndup(s, text_buffer_size); + /* * check that device actually exists */