]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
MINOR: pattern: Remove the flag "PAT_F_FROM_FILE".
authorThierry FOURNIER <tfournier@exceliance.fr>
Tue, 11 Feb 2014 15:19:46 +0000 (16:19 +0100)
committerWilly Tarreau <w@1wt.eu>
Mon, 17 Mar 2014 17:06:08 +0000 (18:06 +0100)
This flag is no longer used. The last place using this, are the display
of the result of pattern matching in the cli command "get map" or "get
acl".

The first parameter of this command is the reference of the file used to
perform the lookup.

include/types/pattern.h
src/acl.c
src/dumpstats.c

index bf13bf78f9e6088efbeb2379ab75dec39615ba41..839eae686f2c464d79bd6a77a9a70ea774e5f355 100644 (file)
@@ -64,8 +64,7 @@ enum pat_match_res {
 /* possible flags for expressions or patterns */
 enum {
        PAT_F_IGNORE_CASE = 1 << 0,       /* ignore case */
-       PAT_F_FROM_FILE   = 1 << 1,       /* pattern comes from a file */
-       PAT_F_TREE        = 1 << 2,       /* some patterns are arranged in a tree */
+       PAT_F_TREE        = 1 << 1,       /* some patterns are arranged in a tree */
 };
 
 /* ACL match methods */
index ca2a5fcf2af6b4ed4d91ff93d545a510bd468102..7efd89e84b728c64004edac68acd555b43cd752f 100644 (file)
--- a/src/acl.c
+++ b/src/acl.c
@@ -449,7 +449,7 @@ struct acl_expr *parse_acl_expr(const char **args, char **err, struct arg_list *
                                goto out_free_expr;
                        }
 
-                       if (!pattern_read_from_file(&expr->pat, PAT_REF_ACL, args[1], patflags | PAT_F_FROM_FILE, load_as_map, err, file, line))
+                       if (!pattern_read_from_file(&expr->pat, PAT_REF_ACL, args[1], patflags, load_as_map, err, file, line))
                                goto out_free_expr;
                        is_loaded = 1;
                        args++;
index 202bd71b814f214a9ce6285d8ba1dd28c5133212..27d440ea11e1fc4ecbd19a1551f3362af6f342cd 100644 (file)
@@ -4990,12 +4990,6 @@ static int stats_map_lookup(struct stream_interface *si)
                                else
                                        chunk_appendf(&trash, ", case=sensitive");
 
-                               /* display source */
-                               if (pat->flags & PAT_F_FROM_FILE)
-                                       chunk_appendf(&trash, ", src=file");
-                               else
-                                       chunk_appendf(&trash, ", src=conf");
-
                                /* display pattern */
                                if (appctx->ctx.map.display_flags == PAT_REF_MAP) {
                                        if (pat->ref && pat->ref->pattern)