|
Message-ID: <CAGSZau3Kc5gz5gLZ2F2Sq7=AogkTYNX0DKpwts++gzbtUjuZ-Q@mail.gmail.com>
Date: Wed, 29 May 2013 22:46:04 +0900
From: plan9assembler <plan9assembler@...il.com>
To: musl@...ts.openwall.com
Subject: Re: util-linux-2.23 mount segmentation fault error
Hi, it didn't solved, still get segfaults..
partially gets segfaults
# this works
.libs/mount /dev/sda1 /mnt
# this segfaults
.libs/umount /mnt
after util-linux-2.23( mount, umount binary) installation,
it segfaults when mount rootfs rw.
so removed mount umount and symlink again.
# rm /mnt/bin/{mount, umount}
# ln -s /mnt/bin/busybox /mnt/bin/mount
# ln -s /mnt/bin/busybox /mnt/bin/umount
On Tue, May 28, 2013 at 6:40 AM, plan9assembler <plan9assembler@...il.com>wrote:
> Hi, i am sure but it works for me.
>
> actually, it little strange, because,
> after modification, first time, it getting segfaults,
> later, it works fine.
>
> flags in util-linux-2.23 was created automatically.
>
> musl linux system could be set by this method:
> https://github.com/pikhq/bootstrap-linux/issues/8
> https://github.com/pikhq/bootstrap-linux/issues/9
> http://plan9assembler.wordpress.com/2013/04/26/bootstrap-linux-musl-cross/
>
> gcc-4.8
> CC = gcc -std=gnu99
> CCDEPMODE = depmode=gcc3
> CFLAGS = -g -O2
> CPP = gcc -E
>
> TIA
>
>
>
>
> On Mon, May 27, 2013 at 11:29 PM, Szabolcs Nagy <nsz@...t70.net> wrote:
>
>> * plan9assembler <plan9assembler@...il.com> [2013-05-27 23:05:37 +0900]:
>> > util-linux-2.23 mount segfault error seems to be solved.
>> > no more segfault error, when i test mount binary.
>> >
>> > i modified follow macros in musl /include/bits/ioctl.h and musl libc
>> > reinstalled.
>> >
>> > - #define _IOR(a,b,c) _IOC(2,(a),(b),sizeof(c))
>> > - #define _IOWR(a,b,c) _IOC(3,(a),(b),sizeof(c))
>> >
>> > + #define _IOR(a,b,c) _IOC(2U,(a),(b),sizeof(c))
>> > + #define _IOWR(a,b,c) _IOC(3U,(a),(b),sizeof(c))
>> >
>>
>> hm are you sure this was the change that solved the segfault?
>>
>> that would be scary since the linux headers have signed
>> int left shift overflows in many places
>> (and as far as i know users of those headers dont use
>> special compilation flags to make signed overflow
>> well-defined like gcc -fwrapv)
>>
>> which compiler did you use and with what flags?
>> (this could break a lot of legacy code)
>>
>
>
Content of type "text/html" skipped
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.