]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
BUG/MINOR: cli: "clear table xx data.xx" does not work anymore
authorWilly Tarreau <w@1wt.eu>
Sat, 13 Apr 2013 07:41:37 +0000 (09:41 +0200)
committerWilly Tarreau <w@1wt.eu>
Sat, 13 Apr 2013 07:41:37 +0000 (09:41 +0200)
Commit 654694e1 introduced in 1.5-dev12 broke the ability to clear
some entries in a table by the value of their data fields.

src/dumpstats.c

index 8ee1eec5c3479154ebac332b2972cadde0c956e7..578247e99283e8feb9b2fd61a9f656890459bc72 100644 (file)
@@ -741,8 +741,8 @@ static void stats_sock_table_key_request(struct stream_interface *si, char **arg
 
 static void stats_sock_table_data_request(struct stream_interface *si, char **args, int action)
 {
-       if (action != STAT_CLI_O_TAB) {
-               si->applet.ctx.cli.msg = "content-based lookup is only supported with the \"show\" action";
+       if (action != STAT_CLI_O_TAB && action != STAT_CLI_O_CLR) {
+               si->applet.ctx.cli.msg = "content-based lookup is only supported with the \"show\" and \"clear\" actions";
                si->applet.st0 = STAT_CLI_PRINT;
                return;
        }