Bug#244997: patch
tag 244997 patch
thanks
It is confused by the dvorak directory. The attached patch should
fix the problem.
--
Matt Kraai kraai@ftbfs.org http://ftbfs.org/
Index: packages/kbd-chooser/findfile.c
===================================================================
--- packages/kbd-chooser/findfile.c (revision 13947)
+++ packages/kbd-chooser/findfile.c (working copy)
@@ -92,6 +92,7 @@
if (d == NULL)
return NULL;
while ((de = readdir(d)) != NULL) {
+ struct stat statbuf;
int okdir;
if (strcmp(de->d_name, ".") == 0 ||
@@ -104,7 +105,6 @@
okdir = (ff && strcmp(de->d_name, fdir) == 0);
if ((secondpass && recdepth) || okdir) {
- struct stat statbuf;
char *a;
a = xmalloc(strlen(dir) + strlen(de->d_name) + 2);
@@ -137,6 +137,9 @@
sprintf(pathname, "%s/%s", dir, de->d_name);
+ if (stat(pathname, &statbuf) == 0 && S_ISDIR(statbuf.st_mode))
+ continue;
+
/* Does tail consist of a known suffix and possibly
a compression suffix? */
for(sp = suf; *sp; sp++) {
Reply to: