From 9a8889e4d0c532b9f77af3a9cc7aae06adebfb83 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Mon, 9 Nov 2009 14:30:11 +0100 Subject: use STREQ, not strcmp: part 1 git grep -l 'strcmp *([^=]*== *0'|xargs \ perl -pi -e 's/\bstrcmp( *\(.*?\)) *== *0/STREQ$1/g' --- daemon/file.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'daemon/file.c') diff --git a/daemon/file.c b/daemon/file.c index 62de1168..252c02c3 100644 --- a/daemon/file.c +++ b/daemon/file.c @@ -481,9 +481,9 @@ do_zfile (const char *method, const char *path) FILE *fp; char line[256]; - if (strcmp (method, "gzip") == 0 || strcmp (method, "compress") == 0) + if (STREQ (method, "gzip") || STREQ (method, "compress")) zcat = "zcat"; - else if (strcmp (method, "bzip2") == 0) + else if (STREQ (method, "bzip2")) zcat = "bzcat"; else { reply_with_error ("zfile: unknown method"); -- cgit