From: Willy Tarreau Date: Tue, 4 Jan 2011 13:57:34 +0000 (+0100) Subject: [MINOR] http: improve url_param pattern extraction to ignore empty values X-Git-Tag: v1.5-dev8~326 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=0013433b0971f42b59958cc3d456a14e31f7e71e;p=thirdparty%2Fhaproxy.git [MINOR] http: improve url_param pattern extraction to ignore empty values It's better to avoid sticking on empty parameter values, as this almost always indicates a missing parameter. Otherwise it's easy to enter a situation where all new visitors stick to the same server. --- diff --git a/src/proto_http.c b/src/proto_http.c index ec1e1808ae..c5debcaff5 100644 --- a/src/proto_http.c +++ b/src/proto_http.c @@ -8340,7 +8340,7 @@ find_url_param_value(char* path, size_t path_l, *value = value_start; *value_l = value_end - value_start; - return 1; + return value_end != value_start; } static int