diff options
author | Renato Botelho <renato@netgate.com> | 2016-02-03 18:01:26 -0200 |
---|---|---|
committer | Renato Botelho <renato@netgate.com> | 2016-02-03 18:01:26 -0200 |
commit | af0758169e63a4e7f6024c241d9254a8bc09908d (patch) | |
tree | a31903fc62c875e8d23a391beb8ae57ed0092c45 /lib/libdpv/dialog_util.c | |
parent | 79f27b5150f7b79a6f1bcd30e9233f1abb9c3e36 (diff) | |
parent | 6114d518f71115abacc5d610c4d668ef6e0b2f37 (diff) | |
download | FreeBSD-src-af0758169e63a4e7f6024c241d9254a8bc09908d.zip FreeBSD-src-af0758169e63a4e7f6024c241d9254a8bc09908d.tar.gz |
Merge remote-tracking branch 'origin/stable/10' into devel
Diffstat (limited to 'lib/libdpv/dialog_util.c')
-rw-r--r-- | lib/libdpv/dialog_util.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/libdpv/dialog_util.c b/lib/libdpv/dialog_util.c index d047a25..21baf98 100644 --- a/lib/libdpv/dialog_util.c +++ b/lib/libdpv/dialog_util.c @@ -261,6 +261,13 @@ dialog_spawn_gauge(char *init_prompt, pid_t *pid) errx(EXIT_FAILURE, "Out of memory?!"); sprintf(dargv[n++], "--title"); dargv[n++] = title; + } else { + if ((dargv[n] = malloc(8)) == NULL) + errx(EXIT_FAILURE, "Out of memory?!"); + sprintf(dargv[n++], "--title"); + if ((dargv[n] = malloc(1)) == NULL) + errx(EXIT_FAILURE, "Out of memory?!"); + *dargv[n++] = '\0'; } if (backtitle != NULL) { if ((dargv[n] = malloc(12)) == NULL) |