summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorGravatar Rosen Penev2020-06-07 22:15:52 -0700
committerGravatar Nikias Bassen2020-11-24 01:15:12 +0100
commit85ede33a2291f7aa7a7bf1cccb6f6ff6da1c046b (patch)
tree139ea960cc24fd2085f8850540b1a4fe18e86911 /tools
parent9f60cdd76b6044931cc2f2b6f2fbec3deb67a425 (diff)
downloadlibplist-85ede33a2291f7aa7a7bf1cccb6f6ff6da1c046b.tar.gz
libplist-85ede33a2291f7aa7a7bf1cccb6f6ff6da1c046b.tar.bz2
Improve code readability by using explicit != 0 compare when using strncmp
[clang-tidy] Found with bugprone-suspicious-string-compare Signed-off-by: Rosen Penev <rosenp@gmail.com>
Diffstat (limited to 'tools')
-rw-r--r--tools/plistutil.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/plistutil.c b/tools/plistutil.c
index bbce7c7..989db35 100644
--- a/tools/plistutil.c
+++ b/tools/plistutil.c
@@ -274,7 +274,7 @@ int main(int argc, char *argv[])
if (plist_out)
{
- if (options->out_file != NULL && strcmp(options->out_file, "-"))
+ if (options->out_file != NULL && strcmp(options->out_file, "-") != 0)
{
FILE *oplist = fopen(options->out_file, "wb");
if (!oplist) {