blob: 57a85adc6c97da75a6cd901bb6be07ad8cae804c (
plain)
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
|
From 1889ef9407bbe8e3db1f4b88d1bc437b31a7d8d0 Mon Sep 17 00:00:00 2001
From: vcrhonek <vcrhonek@fedoraproject.org>
Date: Thu, 24 Jul 2014 17:37:45 +0200
Subject: [PATCH 3/8] fix unprintable (#233525)
original dist-git commit: cd7e072c
---
tw.parse.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/tw.parse.c b/tw.parse.c
index 186fdb5..8af3c50 100644
--- a/tw.parse.c
+++ b/tw.parse.c
@@ -2169,7 +2169,8 @@ print_by_column(Char *dir, Char *items[], int count, int no_file_suffix)
(Strchr(val, 'x') != NULL);
for (i = 0; i < count; i++) { /* find widest string */
- maxwidth = max(maxwidth, (unsigned int) NLSStringWidth(items[i]));
+ if (NLSStringWidth(items[i]) != -1)
+ maxwidth = max(maxwidth, (unsigned int) NLSStringWidth(items[i]));
}
maxwidth += no_file_suffix ? 1 : 2; /* for the file tag and space */
--
1.9.3
|