Browse Source

control.c, bug 374, prevent crash if cend[stackp] is NULL

reported by  PyroPeter
pre-master-46
Holger Vogt 7 years ago
parent
commit
ebe4fd5332
  1. 2
      src/frontend/control.c

2
src/frontend/control.c

@ -639,7 +639,7 @@ cp_evloop(char *string)
for (;;) { for (;;) {
freewl = wlist = getcommand(string); freewl = wlist = getcommand(string);
if (wlist == NULL) { /* End of file or end of user input. */ if (wlist == NULL) { /* End of file or end of user input. */
if (cend[stackp]->co_parent && !string) {
if (cend[stackp] && cend[stackp]->co_parent && !string) {
cp_resetcontrol(); cp_resetcontrol();
continue; continue;
} else { } else {

Loading…
Cancel
Save