From 85d813eeed1d01589231e96d30bf106d86cc7bf1 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Sat, 24 Jan 2026 14:47:08 +0530 Subject: [PATCH] num_items should be decreased even for pending --- kittens/icat/main.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kittens/icat/main.go b/kittens/icat/main.go index f8ff89149..f5896fe5f 100644 --- a/kittens/icat/main.go +++ b/kittens/icat/main.go @@ -335,7 +335,6 @@ func main(cmd *cli.Command, o *Options, args []string) (rc int, err error) { } imgd.use_unicode_placeholder = use_unicode_placeholder imgd.passthrough_mode = passthrough_mode - num_of_items-- if imgd.err != nil { print_error("Failed to process \x1b[31m%s\x1b[39m: %s\r\n", imgd.source_name, imgd.err) } else { @@ -348,6 +347,7 @@ func main(cmd *cli.Command, o *Options, args []string) (rc int, err error) { for num_of_items > 0 { imgd := <-output_channel + num_of_items-- if imgd.input_sequence_number == expecting_input_sequence_number { do_one(imgd) expecting_input_sequence_number++