Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Another signal queueing discrepancy



On Oct 4, 12:02pm, Bart Schaefer wrote:
}
} Which is very strange, because there is no signal queue manipulation in
} any of the compstate handling, and it doesn't occur with other uses of
} [[ ]] expressions in completion (or elsewhere).

Here we go.  Only shows up during completion because that's the only
time heaps_saved is true (SWITCHHEAPS), and --enable-zsh-mem-debug.

diff --git a/Src/mem.c b/Src/mem.c
index db311ef..a1744c6 100644
--- a/Src/mem.c
+++ b/Src/mem.c
@@ -918,16 +918,21 @@ memory_validate(Heapid heap_id)
     if (heaps_saved) {
 	for (node = firstnode(heaps_saved); node; incnode(node)) {
 	    for (h = (Heap)getdata(node); h; h = h->next) {
-		if (h->heap_id == heap_id)
+		if (h->heap_id == heap_id) {
+		    unqueue_signals();
 		    return 0;
+		}
 		for (hs = heaps->sp; hs; hs = hs->next) {
-		    if (hs->heap_id == heap_id)
+		    if (hs->heap_id == heap_id) {
+			unqueue_signals();
 			return 0;
+		    }
 		}
 	    }
 	}
     }
 
+    unqueue_signals();
     return 1;
 }
 /**/



Messages sorted by: Reverse Date, Date, Thread, Author