From fbce6d0215515dc2341767d5aeeecccc29e043eb Mon Sep 17 00:00:00 2001 From: Emeric Brun Date: Thu, 23 Sep 2010 18:10:00 +0200 Subject: [PATCH] [BUG] stick table purge failure if size less than 255 If table size is lower than 256, we can't force to purge old entries. This patch should be backported to 1.4. --- src/stick_table.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/stick_table.c b/src/stick_table.c index 78a0df751..cb9b6b313 100644 --- a/src/stick_table.c +++ b/src/stick_table.c @@ -158,7 +158,7 @@ struct stksess *stksess_new(struct stktable *t, struct stktable_key *key) if ( t->nopurge ) return NULL; - if (!stktable_trash_oldest(t, t->size >> 8)) + if (!stktable_trash_oldest(t, (t->size >> 8) + 1)) return NULL; }