summaryrefslogtreecommitdiffstats
path: root/daemon/guestfsd.c
diff options
context:
space:
mode:
authorJim Meyering <meyering@redhat.com>2009-11-09 14:21:46 +0100
committerJim Meyering <meyering@redhat.com>2009-11-09 22:34:16 +0100
commit627f89351d06e43564b47ea42cabaa522284c2a1 (patch)
tree088ef0ed9661ac5f76e61373c899bfe2edce9d0b /daemon/guestfsd.c
parent29842da1379ece83eae98ee786b475ae161f1687 (diff)
downloadlibguestfs-627f89351d06e43564b47ea42cabaa522284c2a1.tar.gz
libguestfs-627f89351d06e43564b47ea42cabaa522284c2a1.tar.xz
libguestfs-627f89351d06e43564b47ea42cabaa522284c2a1.zip
change strncmp(...) != 0 to STRNEQLEN(...)
git grep -l 'strncmp *([^=]*!= *0'|xargs \ perl -pi -e 's/\bstrncmp( *\(.*?\)) *!= *0/STRNEQLEN$1/g'
Diffstat (limited to 'daemon/guestfsd.c')
-rw-r--r--daemon/guestfsd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/daemon/guestfsd.c b/daemon/guestfsd.c
index d16826f0..61a62368 100644
--- a/daemon/guestfsd.c
+++ b/daemon/guestfsd.c
@@ -945,7 +945,7 @@ device_name_translation (char *device, const char *func)
}
/* If the name begins with "/dev/sd" then try the alternatives. */
- if (strncmp (device, "/dev/sd", 7) != 0)
+ if (STRNEQLEN (device, "/dev/sd", 7))
goto error;
device[5] = 'h'; /* /dev/hd (old IDE driver) */