netsnmp: handle libnl dependency properly
[buildroot-gz.git] / package / matchbox-lib / 0001-index-is-legacy.patch
blobb486fb18d4c6461efc1064373b7616fdc8d89617
1 index() is a legacy function, not implemented in some uClibc
2 configurations.
4 Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
5 ---
6 libmb/mbexp.c | 2 +-
7 libmb/mbmenu.c | 2 +-
8 2 files changed, 2 insertions(+), 2 deletions(-)
10 Index: libmatchbox-1.9/libmb/mbexp.c
11 ===================================================================
12 --- libmatchbox-1.9.orig/libmb/mbexp.c
13 +++ libmatchbox-1.9/libmb/mbexp.c
14 @@ -492,7 +492,7 @@
16 /* get the family */
18 - if (index(spec, ',') != NULL || index(spec, '-') != NULL)
19 + if (strchr(spec, ',') != NULL || strchr(spec, '-') != NULL)
20 has_comma_delim = True;
22 while (!got_family) {
23 Index: libmatchbox-1.9/libmb/mbmenu.c
24 ===================================================================
25 --- libmatchbox-1.9.orig/libmb/mbmenu.c
26 +++ libmatchbox-1.9/libmb/mbmenu.c
27 @@ -433,7 +433,7 @@
29 s = p;
30 found = NULL;
31 - while(index("/\0", *p) == NULL) p++;
32 + while(strchr("/\0", *p) == NULL) p++;
33 if (*p != '\0') { *p = '\0'; p++; };
35 item = current->items;