diff options
author | Hristo Venev <hristo@venev.name> | 2020-06-06 21:35:01 +0300 |
---|---|---|
committer | Hristo Venev <hristo@venev.name> | 2020-06-06 21:36:15 +0300 |
commit | 37f521616512d4f96eb4d40f62b784476d5a5f5d (patch) | |
tree | 237e7037e323b1f17c1aef1f2f8fc678d7f4bdea | |
parent | 6692d69f8e2c2671135550fc4c633aa2aee147d2 (diff) |
Slightly improve string copy loop.
-rw-r--r-- | vc-log.c | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -113,6 +113,7 @@ static char *vc_read_str(size_t off) { } size_t alloc2 = alloc + (alloc << 2); + alloc2 += (-alloc2) % 16; char *r2 = realloc(r, alloc2); if(!r2) abort(); r = r2; |