From d2aa0407c4286fe621cb87619f6f8ec007c53342 Mon Sep 17 00:00:00 2001 From: Eric Leblond Date: Wed, 22 Aug 2012 14:24:30 +0200 Subject: [PATCH] defrag: Fix unittest logic. We've linked the size of hash with trackers. Thus calling DefragInit() after setting the configuration variable is more logic. --- src/defrag.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/defrag.c b/src/defrag.c index 8e69612909..f619638fa2 100644 --- a/src/defrag.c +++ b/src/defrag.c @@ -2411,14 +2411,14 @@ DefragTimeoutTest(void) int ret = 0; DefragContext *dc = NULL; - DefragInit(); - /* Setup a small numberr of trackers. */ if (ConfSet("defrag.trackers", "16", 1) != 1) { printf("ConfSet failed: "); goto end; } + DefragInit(); + dc = DefragContextNew(); if (dc == NULL) goto end;