diff options
author | Jim Meyering <meyering@redhat.com> | 2009-11-09 14:21:46 +0100 |
---|---|---|
committer | Jim Meyering <meyering@redhat.com> | 2009-11-09 22:34:16 +0100 |
commit | 627f89351d06e43564b47ea42cabaa522284c2a1 (patch) | |
tree | 088ef0ed9661ac5f76e61373c899bfe2edce9d0b /examples | |
parent | 29842da1379ece83eae98ee786b475ae161f1687 (diff) | |
download | libguestfs-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 'examples')
-rw-r--r-- | examples/to-xml.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/to-xml.c b/examples/to-xml.c index 6d0a1dfb..f48d1ca7 100644 --- a/examples/to-xml.c +++ b/examples/to-xml.c @@ -149,7 +149,7 @@ display_partitions (guestfs_h *g, const char *dev) * That's a limitation of sorts of the Linux kernel. (Actually, * we could do this if we add the kpartx program to libguestfs). */ - if (strncmp (dev, "/dev/sd", 7) != 0 || isdigit (dev[strlen(dev)-1])) { + if (STRNEQLEN (dev, "/dev/sd", 7) || isdigit (dev[strlen(dev)-1])) { printf ("<vm-image dev=\"%s\"/>\n", dev); return; } |