Commit 4c47a36e authored by Poul-Henning Kamp's avatar Poul-Henning Kamp

Fix a bug discovered by inspection:

If we fail to allocate storage, try a smaller chunk, not a larger one.
parent d175906e
......@@ -180,7 +180,7 @@ stv_alloc(struct stevedore *stv, size_t size)
if (size <= cache_param->fetch_chunksize)
break;
size >>= 1;
size <<= 1;
}
if (st != NULL)
CHECK_OBJ_NOTNULL(st, STORAGE_MAGIC);
......
......@@ -17,4 +17,4 @@ client c1 {
expect resp.status == 503
} -run
varnish v1 -expect SMA.test.c_fail < 5
varnish v1 -expect SMA.test.c_fail < 50
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment