aboutsummaryrefslogtreecommitdiff
path: root/src/common/container.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/common/container.c')
-rw-r--r--src/common/container.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/common/container.c b/src/common/container.c
index 36234743ac..e3523735dd 100644
--- a/src/common/container.c
+++ b/src/common/container.c
@@ -87,7 +87,7 @@ smartlist_ensure_capacity(smartlist_t *sl, int size)
int higher = sl->capacity * 2;
while (size > higher)
higher *= 2;
- tor_assert(higher > sl->capacity); /* detect overflow */
+ tor_assert(higher > 0); /* detect overflow */
sl->capacity = higher;
sl->list = tor_realloc(sl->list, sizeof(void*)*sl->capacity);
}