ref: 57a6cfecbc447d44c11c7bc590706ea252c511a3
parent: 954f906c3b2f09299f7e6ee5dfefc2ae466e477a
author: Ori Bernstein <ori@eigenstate.org>
date: Thu Nov 5 21:18:02 EST 2020
remove debugspam
--- a/mail.h
+++ b/mail.h
@@ -45,6 +45,7 @@
int ctl;
int addr;
int data;
+ int open;
};
/*
--- a/mbox.c
+++ b/mbox.c
@@ -342,10 +342,8 @@
if((m = mesgload(name)) == nil)
goto error;
- if(digest != nil && strcmp(digest, m->digest) != 0){
- fprint(2, "mismatched digest: %s %s\n", m->digest, digest);
+ if(digest != nil && strcmp(digest, m->digest) != 0)
goto error;
- }
/* if we already have a dummy, populate it */
if((p = lookupid(m->messageid)) != nil){
c = p->child;
--- a/mesg.c
+++ b/mesg.c
@@ -327,7 +327,10 @@
static void
mesgquit(Mesg *m, char **, int)
{
+ if(fprint(m->ctl, "del\n") == -1)
+ return;
m->quitting = 1;
+ m->open = 0;
}
static Fn mesgfn[] = {
--- a/win.c
+++ b/win.c
@@ -319,10 +319,8 @@
if(strncmp(text, mbox.path, strlen(mbox.path)) == 0)
return 1;
else if(regexec(mesgpat, text, nil, 0)){
- print("matchedx\n");
if((p = strchr(text, '/')) != nil)
p[1] = 0;
- print("matched\n");
return 1;
}
return 0;