summaryrefslogtreecommitdiff
path: root/ex/ex_shell.c
diff options
context:
space:
mode:
Diffstat (limited to 'ex/ex_shell.c')
-rw-r--r--ex/ex_shell.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/ex/ex_shell.c b/ex/ex_shell.c
index 7b483fd4e14c..7d73253dfbc5 100644
--- a/ex/ex_shell.c
+++ b/ex/ex_shell.c
@@ -48,8 +48,7 @@ ex_shell(SCR *sp, EXCMD *cmdp)
* XXX
* Assumes all shells use -i.
*/
- (void)asprintf(&buf, "%s -i", O_STR(sp, O_SHELL));
- if (buf == NULL) {
+ if (asprintf(&buf, "%s -i", O_STR(sp, O_SHELL)) == -1) {
msgq(sp, M_SYSERR, NULL);
return (1);
}