shithub: gefs

Download patch

ref: 5f4bc3535731f025153ee9b21af7fb8cbf8c3fc6
parent: 5957ad359bc5e536af25a9743e3d87376e523744
author: Ori Bernstein <ori@eigenstate.org>
date: Thu Dec 7 13:34:09 EST 2023

snap: we may have flushed the deadlist insertion

we don't need to write it back in this case, and in fact
we will trigger an assertion if we try. So, check and skip
if the dlist block is clean.

--- a/snap.c
+++ b/snap.c
@@ -568,7 +568,7 @@
 	}
 	if(dl->ins == nil || Logspc - dl->ins->logsz < Logslop){
 		b = newblk(&fs->snap, Tdlist, 0);
-		if(dl->ins != nil)
+		if(dl->ins != nil && checkflag(b, Bdirty))
 			enqueue(dl->ins);
 		if(dl->tl.addr == -1)
 			dl->tl = b->bp;