Package: kbd-chooser
Version: 0.23 (not installed)
Severity: normal
Tags: patch

Hi,

here are 2 patchs. The first one corrects a small error. The second one
makes kbd-chooser handling only console-keymaps-* files. In
maplist_parse_file:374, there is a strlen("console-keymaps-").

thanks for your work.

-- System Information:
Debian Release: testing/unstable
Architecture: i386
Kernel: Linux thomas 2.4.21-3-k7 #1 Sun Jul 20 19:23:36 EST 2003 i686
Locale: LANG=C, LC_CTYPE=C


-- 
Thomas Poindessous

Index: kbd-chooser.c
===================================================================
RCS file: /cvs/debian-boot/debian-installer/tools/kbd-chooser/kbd-chooser.c,v
retrieving revision 1.27
diff -u -r1.27 kbd-chooser.c
--- kbd-chooser.c       15 Jul 2003 08:29:40 -0000      1.27
+++ kbd-chooser.c       27 Jul 2003 22:16:48 -0000
@@ -446,7 +446,7 @@
                        if (strncmp (ent->d_name, "console-keymaps-", 16) == 0)
                                strcpy (p, ent->d_name);
                        else
-                               strncpy (p, ent->d_name, strchr (ent->d_name, '.') - 
p);
+                               strncpy (p, ent->d_name, strchr (ent->d_name, '.') - 
ent->d_name);
                        maplist_select (maplist_parse_file (fullname));
                }
        }
Index: kbd-chooser.c
===================================================================
RCS file: /cvs/debian-boot/debian-installer/tools/kbd-chooser/kbd-chooser.c,v
retrieving revision 1.27
diff -u -r1.27 kbd-chooser.c
--- kbd-chooser.c       15 Jul 2003 08:29:40 -0000      1.27
+++ kbd-chooser.c       27 Jul 2003 22:17:39 -0000
@@ -443,11 +443,10 @@
                        /* two types of name allowed (for the moment; )
                         * legacy 'console-keymaps-* names and *.keymaps names
                         */
-                       if (strncmp (ent->d_name, "console-keymaps-", 16) == 0)
+                       if (strncmp (ent->d_name, "console-keymaps-", 16) == 0) {
                                strcpy (p, ent->d_name);
-                       else
-                               strncpy (p, ent->d_name, strchr (ent->d_name, '.') - 
p);
-                       maplist_select (maplist_parse_file (fullname));
+                               maplist_select (maplist_parse_file (fullname));
+                       }
                }
        }
 

Reply via email to