author | Rich Burridge <rich.burridge@oracle.com> |
Tue, 03 Mar 2015 11:01:06 -0800 | |
changeset 3897 | cd126ba3fdda |
permissions | -rw-r--r-- |
3897
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
1 |
Fix "line 579: undefined symbol: UL_SCNsA" problem at compile time in |
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
2 |
lib/colors.c |
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
3 |
|
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
4 |
Problem previously reported at: |
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
5 |
http://www.spinics.net/lists/util-linux-ng/msg10496.html |
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
6 |
|
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
7 |
Change taken from upstream git repo: |
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
8 |
https://github.com/karelzak/util-linux/blob/master/lib/colors.c |
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
9 |
|
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
10 |
--- util-linux-2.25.2/lib/colors.c.orig 2015-02-16 16:36:01.215073454 -0800 |
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
11 |
+++ util-linux-2.25.2/lib/colors.c 2015-03-01 10:53:21.301521771 -0800 |
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
12 |
@@ -576,9 +577,7 @@ |
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
13 |
if (*p == '\0' || *p == '#') |
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
14 |
continue; |
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
15 |
|
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
16 |
- rc = sscanf(p, UL_SCNsA" " /* name */ |
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
17 |
- UL_SCNsA, /* color */ |
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
18 |
- &cn, &seq); |
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
19 |
+ rc = sscanf(p, "%128[^ ] %128[^\n ]", cn, seq); |
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
20 |
if (rc == 2 && cn && seq) |
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
21 |
rc = colors_add_scheme(cc, cn, seq); /* set rc=0 on success */ |
cd126ba3fdda
20623340 text-utilities should be updated to version 2.25.2
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
22 |
if (rc) { |