else if (!parse_DATA_LIST_vars (lexer, dict, names, nnames, PV_APPEND))
goto fail;
}
- return 1;
+ if (*nnames == 0)
+ goto fail;
+
+ return true;
fail:
for (i = 0; i < *nnames; i++)
free (*names);
*names = NULL;
*nnames = 0;
- return 0;
+ return false;
}
/* Parses a list of variables where some of the variables may be
])
AT_CLEANUP
+
+
+
+AT_SETUP([RECODE crash on invalid dest variable])
+
+AT_DATA([recode.sps],[dnl
+DATA LIST LIST NOTABLE/x (f1) s (a4) t (a10).
+MISSING VALUES x(9)/s('xxx').
+BEGIN DATA.
+0, '', ''
+1, a, a
+2, ab, ab
+3, abc, abc
+END DATA.
+
+RECODE x (1=9) INTO ".
+EXECUTE.
+])
+
+AT_CHECK([pspp -O format=csv recode.sps], [1], [ignore])
+
+AT_CLEANUP