]> andersk Git - libyaml.git/commitdiff
fix clang -Wlogical-op warnings
authorReini Urban <rurban@cpanel.net>
Tue, 13 Sep 2016 13:37:56 +0000 (15:37 +0200)
committerTina Müller <cpan2@tinita.de>
Wed, 18 Jul 2018 19:22:15 +0000 (21:22 +0200)
Commit amended by @perlpunk after suggestion from @tlsa

src/scanner.c
src/yaml_private.h

index cbe5c6fd077ad7fcfee48ad97a0453de594ec9a2..ceee7496a8a68d97eeb44630f4e229d005cfa6e9 100644 (file)
@@ -2860,7 +2860,7 @@ yaml_parser_scan_block_scalar(yaml_parser_t *parser, yaml_token_t *token,
 
     if (!CACHE(parser, 1)) goto error;
 
-    while ((int)parser->mark.column == indent && !IS_Z(parser->buffer))
+    while ((int)parser->mark.column == indent && !(IS_Z(parser->buffer)))
     {
         /*
          * We are at the beginning of a non-empty line.
index eb722077dfc01d72883c228883749ea72463bb2c..d2971b8c1b5f0db16d6eedda220019ac36c0af52 100644 (file)
@@ -171,14 +171,14 @@ yaml_string_join(
  * Check the octet at the specified position.
  */
 
-#define CHECK_AT(string,octet,offset)                                           \
+#define CHECK_AT(string,octet,offset)                   \
     ((string).pointer[offset] == (yaml_char_t)(octet))
 
 /*
  * Check the current octet in the buffer.
  */
 
-#define CHECK(string,octet) CHECK_AT((string),(octet),0)
+#define CHECK(string,octet) (CHECK_AT((string),(octet),0))
 
 /*
  * Check if the character at the specified position is an alphabetical
This page took 0.193764 seconds and 5 git commands to generate.