Fail commands properly when they get aborted
The old code didn't return RET_SYN when aborting at the following prompts: * designate second argument * morale second argument * route second argument * set third argument * tend fourth argument * zdone last argument
This commit is contained in:
parent
a7cf69af50
commit
be41e70fa8
6 changed files with 14 additions and 12 deletions
|
@ -93,7 +93,7 @@ set(void)
|
|||
sprintf(prompt, "%s #%d; Price? ",
|
||||
trade_nameof(&trade, &item), ni.cur);
|
||||
if ((p = getstarg(player->argp[3], prompt, buf)) == 0)
|
||||
break;
|
||||
return RET_SYN;
|
||||
if (!trade_check_item_ok(&item))
|
||||
return RET_FAIL;
|
||||
if ((price = atoi(p)) < 0)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue