diff options
| author | 2022-08-04 07:39:23 +0200 | |
|---|---|---|
| committer | 2022-08-04 07:39:23 +0200 | |
| commit | bb1d4b4a3e51a06fb0530dfc271a97a6cd88cc73 (patch) | |
| tree | f300325814bc30e64f858ee313b8260a14d8df90 /bootstrap/util.c | |
| parent | 1625c50f0c0e4b1c7ba01a5df5713efaf6dce606 (diff) | |
stuff
Diffstat (limited to 'bootstrap/util.c')
| -rw-r--r-- | bootstrap/util.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/bootstrap/util.c b/bootstrap/util.c index 4aebbe6..855091a 100644 --- a/bootstrap/util.c +++ b/bootstrap/util.c @@ -61,13 +61,13 @@ xrealloc(void *p, size_t n) { char * xasprintf(const char *fmt, ...) { va_list ap, aq; - int n = 32, m; + int n = 16, m; char *str = xcalloc(n, 1); va_start(ap, fmt); m = vsnprintf(str, n, fmt, ap) + 1; + str = xrealloc(str, m); if (m > n) { va_copy(aq, ap); - str = xrealloc(str, m); vsprintf(str, fmt, ap); va_end(aq); } |