diff options
author | Mike Yuan <me@yhndnzj.com> | 2023-03-22 13:15:19 +0100 |
---|---|---|
committer | Mike Yuan <me@yhndnzj.com> | 2023-03-22 16:25:25 +0100 |
commit | da037170c4bb63eab0887fe26c15ae3d3e60b809 (patch) | |
tree | 93f4ee96c69d9ec889be7c16130fbdce1ab55375 /src/shared/edit-util.c | |
parent | coredump: use unaligned_read_ne{32,64}() to parse auxv (diff) | |
download | systemd-da037170c4bb63eab0887fe26c15ae3d3e60b809.tar.xz systemd-da037170c4bb63eab0887fe26c15ae3d3e60b809.zip |
edit-util: alloc correct amount of memory
Diffstat (limited to '')
-rw-r--r-- | src/shared/edit-util.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/shared/edit-util.c b/src/shared/edit-util.c index b59f129528..f1eb7987f4 100644 --- a/src/shared/edit-util.c +++ b/src/shared/edit-util.c @@ -71,7 +71,7 @@ int edit_files_add( if (edit_files_contains(context, path)) return 0; - if (!GREEDY_REALLOC0(context->files, context->n_files + 2)) + if (!GREEDY_REALLOC(context->files, context->n_files + 1)) return log_oom(); new_path = strdup(path); |