misccoms.c, noask

This commit is contained in:
rlar 2012-05-17 19:06:08 +02:00
parent 41de8d95ff
commit b9c0159cd6
1 changed files with 3 additions and 9 deletions

View File

@ -36,20 +36,14 @@ com_quit(wordlist *wl)
struct plot *pl;
int ncc = 0, npl = 0;
char buf[64];
bool noask;
noask = cp_getvar("noaskquit", CP_BOOL, NULL);
bool noask =
(wl && wl->wl_word && cieq(wl->wl_word, "noask")) ||
cp_getvar("noaskquit", CP_BOOL, NULL);
gr_clean();
cp_ccon(FALSE);
if(wl)
if(wl->wl_word)
if(cieq(wl->wl_word, "noask")) {
byemesg();
exit(EXIT_NORMAL);
}
/* Make sure the guy really wants to quit. */
if (!ft_nutmeg && !noask) {
for (cc = ft_circuits; cc; cc = cc->ci_next)