shithub: gefs

Download patch

ref: 421f12180aa74b9628ba189b7bef9bdb24319935
parent: 2106bbe66a53e35785afbb26bd7620eea792c0bf
author: Ori Bernstein <ori@eigenstate.org>
date: Sat Apr 8 17:55:30 EDT 2023

fs: fix empty directory check

--- a/fs.c
+++ b/fs.c
@@ -1476,7 +1476,7 @@
 		goto Out;
 	if((e = btnext(f->mnt->root, &s, &s.kv)) != nil)
 		goto Out;
-	if(s.done)
+	if(!s.done)
 		e = Enempty;
 Out:
 	btexit(f->mnt->root, &s);