summaryrefslogtreecommitdiffstats
path: root/source/a/mkinitrd/fixes-1.20.1/busybox-1.20.1-man.patch
blob: f382e078f47e635883c82a87bf588416097e2fe9 (about) (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
--- busybox-1.20.1/miscutils/man.c
+++ busybox-1.20.1-man/miscutils/man.c
@@ -129,27 +129,21 @@ static int show_manpage(const char *page
 #endif
 #if ENABLE_FEATURE_SEAMLESS_XZ
 	strcpy(ext, "xz");
-	if (run_pipe(pager, man_filename, man, level))
+	if (run_pipe(pager, filename_with_zext, man, level))
 		return 1;
 #endif
 #if ENABLE_FEATURE_SEAMLESS_BZ2
 	strcpy(ext, "bz2");
-	if (run_pipe(pager, man_filename, man, level))
+	if (run_pipe(pager, filename_with_zext, man, level))
 		return 1;
 #endif
 #if ENABLE_FEATURE_SEAMLESS_GZ
 	strcpy(ext, "gz");
-	if (run_pipe(pager, man_filename, man, level))
+	if (run_pipe(pager, filename_with_zext, man, level))
 		return 1;
 #endif
 
-#if SEAMLESS_COMPRESSION
-	ext[-1] = '\0';
-#endif
-	if (run_pipe(pager, man_filename, man, level))
-		return 1;
-
-	return 0;
+	return run_pipe(pager, man_filename, man, level);
 }
 
 int man_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;