[Pkg-sysvinit-devel] Bug#547073: sysvinit: init should not clear utf8 flag
Samuel Thibault
sthibault at debian.org
Wed Sep 16 23:42:54 UTC 2009
Package: sysvinit
Version: 2.86.ds1-65
Severity: normal
Hello,
init sets c_iflag from scratch. This however clears the IUTF8
flag that the kernel sets according to the vt.default_utf8 kernel
option, resulting to odd behavior of backspace applied to non-ascii
characters. Just like c_cflag flags, init should not clear it, see
attached patch.
Samuel
-- System Information:
Debian Release: squeeze/sid
APT prefers testing
APT policy: (990, 'testing'), (500, 'unstable'), (500, 'stable'), (1, 'experimental')
Architecture: amd64 (x86_64)
Kernel: Linux 2.6.31 (SMP w/2 CPU cores)
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash
Versions of packages sysvinit depends on:
ii file-rc 0.8.11 Alternative boot mechanism using a
ii initscripts 2.86.ds1-65 scripts for initializing and shutt
ii libc6 2.9-25 GNU C Library: Shared libraries
ii libselinux1 2.0.85-4 SELinux runtime shared libraries
ii libsepol1 2.0.38-2 SELinux library for manipulating b
ii sysvinit-utils 2.86.ds1-65 System-V-like utilities
sysvinit recommends no packages.
sysvinit suggests no packages.
-- no debconf information
--
Samuel Thibault <samuel.thibault at fnac.net>
<s> je la connaissais pas celle la : "make: Entering an unknown directory"
-+- #ens-mim -+-
-------------- next part --------------
diff --git a/sysdeps/mach/hurd/brk.c b/sysdeps/mach/hurd/brk.c
index 931b260..4a135d3 100644
--- a/sysdeps/mach/hurd/brk.c
+++ b/sysdeps/mach/hurd/brk.c
@@ -64,7 +64,7 @@ weak_alias (__brk, brk)
int
_hurd_set_brk (vm_address_t addr)
{
- error_t err;
+ error_t err = 0;
vm_address_t pagend = round_page (addr);
vm_address_t pagebrk = round_page (_hurd_brk);
long int rlimit;
@@ -101,8 +101,22 @@ _hurd_set_brk (vm_address_t addr)
if (pagend > _hurd_data_end)
{
+ vm_address_t alloc_start = _hurd_data_end;
+
/* We didn't allocate enough space! Hopefully we can get some more! */
- err = __vm_allocate (__mach_task_self (), &pagebrk, pagend - pagebrk, 0);
+
+ if (_hurd_data_end > pagebrk)
+ /* First finish allocation */
+ err = __vm_protect (__mach_task_self (), pagebrk,
+ alloc_start - pagebrk, 0,
+ VM_PROT_READ|VM_PROT_WRITE|VM_PROT_EXECUTE);
+ if (! err)
+ _hurd_brk = alloc_start;
+
+ if (! err)
+ err = __vm_allocate (__mach_task_self (), &alloc_start,
+ pagend - alloc_start, 0);
+
if (! err)
_hurd_data_end = pagend;
}
More information about the Pkg-sysvinit-devel
mailing list