From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from localhost by hawkwind.utcs.toronto.edu with SMTP id <2688>; Tue, 25 May 1993 19:07:41 -0400 To: Sam Fans Subject: Re: quit with modified files In-reply-to: schwartz's message of Mon, 24 May 93 14:48:36 -0400. <93May24.144733edt.2580@groucho.cs.psu.edu> Date: Tue, 25 May 1993 19:07:35 -0400 From: Chris Siebenmann Message-Id: <93May25.190741edt.2688@hawkwind.utcs.toronto.edu> It's a bug. It happens if you call in a clean file and immediately try to quit; edit() in sam/sam.c doesn't set the global dirty file state quite right. I've attached a patch. - cks *** /tmp/,RCSt1a04954 Tue May 25 19:05:06 1993 --- sam/sam.c Tue May 25 18:47:16 1993 *************** *** 331,337 **** f->ndot.r.p1 = addr.r.p2, f->ndot.r.p2 = addr.r.p2+p; else f->ndot.r.p1 = f->ndot.r.p2 = 0; ! quitok = f->closeok = empty; state(f, empty && !nulls? Clean : Dirty); if(cmd == 'e') filename(f); --- 331,337 ---- f->ndot.r.p1 = addr.r.p2, f->ndot.r.p2 = addr.r.p2+p; else f->ndot.r.p1 = f->ndot.r.p2 = 0; ! quitok = quitok ? (f->closeok = empty) : FALSE; state(f, empty && !nulls? Clean : Dirty); if(cmd == 'e') filename(f);