NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
lib/40477: [PATCH] fix libedit build on Glibc systems not based on Linux
>Number: 40477
>Category: lib
>Synopsis: [PATCH] fix libedit build on Glibc systems not based on Linux
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: lib-bug-people
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sun Jan 25 20:25:00 +0000 2009
>Originator: Robert Millan
>Release: N/A
>Organization:
N/A
>Environment:
>Description:
This patch fixes build of libedit on Glibc systems other than those based on
Linux.
Index: lib/libedit/filecomplete.c
===================================================================
RCS file: /cvsroot/src/lib/libedit/filecomplete.c,v
retrieving revision 1.12
diff -u -p -r1.12 filecomplete.c
--- lib/libedit/filecomplete.c 11 Jan 2009 15:00:23 -0000 1.12
+++ lib/libedit/filecomplete.c 25 Jan 2009 20:20:51 -0000
@@ -208,7 +208,7 @@ fn_filename_completion_function(const ch
/* otherwise, get first entry where first */
/* filename_len characters are equal */
if (entry->d_name[0] == filename[0]
-#if defined(__SVR4) || defined(__linux__)
+#if defined(__SVR4) || defined(__linux__) || defined(__GLIBC__)
&& strlen(entry->d_name) >= filename_len
#else
&& entry->d_namlen >= filename_len
@@ -220,7 +220,7 @@ fn_filename_completion_function(const ch
if (entry) { /* match found */
-#if defined(__SVR4) || defined(__linux__)
+#if defined(__SVR4) || defined(__linux__) || defined(__GLIBC__)
len = strlen(entry->d_name);
#else
len = entry->d_namlen;
>How-To-Repeat:
>Fix:
Home |
Main Index |
Thread Index |
Old Index