summaryrefslogtreecommitdiff
path: root/source/ap/man/makewhatis.bzcat.bugfix.diff
blob: 27ca6cbc14b5329523a735cdb9f07384bdce876f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
From e488c56037adbcff4be255bb95feaedb147898e9 Mon Sep 17 00:00:00 2001
From: mancha <mancha1 AT zoho1 DOT com>
Date: Sat, 18 Oct 2014
Subject: awk like a boss

"To fall-through, or not to fall-through, that is the transgression."

--- a/src/makewhatis.sh
+++ b/src/makewhatis.sh
@@ -264,7 +264,7 @@ do
 			 match(filename,"\\.z$") || match(filename,"\\.gz$");
 	      if (!use_zcat)
 		use_bzcat = match(filename,"\\.bz2");
-              if(!use_bzcat)
+              if (!use_bzcat && !use_zcat)
                 use_lzcat = match(filename,"\\.lzma");
               if (use_zcat || use_bzcat || use_lzcat ) {
 		filename_no_gz = substr(filename, 0, RSTART - 1);