summaryrefslogtreecommitdiff
path: root/editors/awk.c
diff options
context:
space:
mode:
Diffstat (limited to 'editors/awk.c')
-rw-r--r--editors/awk.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/editors/awk.c b/editors/awk.c
index 1bdb9b9..5a504d0 100644
--- a/editors/awk.c
+++ b/editors/awk.c
@@ -2145,7 +2145,8 @@ static var *evaluate(node *op, var *res)
X.rsm = newfile(R.s);
if (! X.rsm->F) {
if (opn == '|') {
- if((X.rsm->F = popen(R.s, "w")) == NULL)
+ X.rsm->F = popen(R.s, "w");
+ if (X.rsm->F == NULL)
bb_perror_msg_and_die("popen");
X.rsm->is_pipe = 1;
} else {