]> granicus.if.org Git - neomutt/commitdiff
boolify Pattern.ready
authorRichard Russon <rich@flatcap.org>
Thu, 13 Jun 2019 10:22:33 +0000 (11:22 +0100)
committerRichard Russon <rich@flatcap.org>
Sat, 15 Jun 2019 20:34:45 +0000 (21:34 +0100)
pattern.c

index 66753a08466efb75a9b496fabbd55e58d6812c9f..bfdc4308a0239a8312f5daaea5e70bbc94d94c61 100644 (file)
--- a/pattern.c
+++ b/pattern.c
@@ -131,11 +131,11 @@ enum EatRangeError
  */
 struct RangeRegex
 {
-  const char *raw; /**< regex as string */
-  int lgrp;        /**< paren group matching the left side */
-  int rgrp;        /**< paren group matching the right side */
-  int ready;       /**< compiled yet? */
-  regex_t cooked;  /**< compiled form */
+  const char *raw; ///< Regex as string
+  int lgrp;        ///< Paren group matching the left side
+  int rgrp;        ///< Paren group matching the right side
+  bool ready;      ///< Compiled yet?
+  regex_t cooked;  ///< Compiled form
 };
 
 /**
@@ -940,7 +940,7 @@ static int eat_range_by_regex(struct Pattern *pat, struct Buffer *s, int kind,
     regerr = regcomp(&pspec->cooked, pspec->raw, REG_EXTENDED);
     if (regerr != 0)
       return report_regerror(regerr, &pspec->cooked, err);
-    pspec->ready = 1;
+    pspec->ready = true;
   }
 
   /* Match the pattern buffer against the compiled regex.