1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

fixed two compiling bugs for libedit

This commit is contained in:
vva@eagle.mysql.r18.ru
2004-08-31 18:29:01 +05:00
parent 940753e342
commit 53b804a679
4 changed files with 44 additions and 2 deletions

View File

@ -1345,7 +1345,7 @@ filename_completion_function(const char *text, int state)
/* otherwise, get first entry where first */
/* filename_len characters are equal */
if (entry->d_name[0] == filename[0]
#if defined(__SVR4) || defined(__linux__)
#ifndef STRUCT_DIRENT_HAS_D_NAMLEN
&& strlen(entry->d_name) >= filename_len
#else
&& entry->d_namlen >= filename_len
@ -1358,7 +1358,7 @@ filename_completion_function(const char *text, int state)
if (entry) { /* match found */
struct stat stbuf;
#if defined(__SVR4) || defined(__linux__)
#ifndef STRUCT_DIRENT_HAS_D_NAMLEN
len = strlen(entry->d_name) +
#else
len = entry->d_namlen +