shithub: Nail

Download patch

ref: 9d6d47c52cd0b0c4c7233c4e042748ebcd140cbc
parent: 7b17c392d3d9a3616009d11681b6f6dfdbf2ed04
author: Ori Bernstein <ori@eigenstate.org>
date: Thu Nov 12 18:24:21 EST 2020

tighten assertion: >= 0 to >0

--- a/mbox.c
+++ b/mbox.c
@@ -672,7 +672,7 @@
 		if(r->nsub > 0){
 			ln = mesglineno(r, nil);
 			nr = r->nsub + (r->flags & Fdummy) ? 0 : 1;
-			assert(nr >= 0);
+			assert(nr > 0);
 			fprint(mbox.addr, "%d,%d", ln, ln+nr-1);
 			write(mbox.data, "", 0);
 			reinsert(r);