busybox-1.9.0 / fdisk -l segfaults

walter harms WHarms at bfs.de
Thu Jan 24 10:21:35 UTC 2008



Joakim Tjernlund wrote:
> On Wed, 2008-01-23 at 18:41 +0100, Christian MICHON wrote:
>> On Jan 23, 2008 3:00 PM, Christian MICHON <christian.michon at gmail.com> wrote:
>>> Thanks! I missed that part (was browsing the whole busybox mailing
>>> list archives without realizing it could be do..while(0) )
>>>
>>> That was actually a dangerous commit. gcc-3.4.6 is not that outdated
>>> by the way...
>>>
>>> I'll do some test tonight on this. Cool finding!
>> that was it. I've a functional fdisk now :)
>>
>> I'll look carefully now for those do...while(0) in the next releases.
>> Thanks for this useful tip. I should be able to cut a new release of
>> my distro now.
> 
> Havn't followed this thread, but are you saying that your gcc-3.4.6
> can't compile do { } while(0) correctly?
> 
> We are using gentoo gcc-3.4.6-r2 to crosscompile to powerpc and I really
> don't like that it might miscompile do { } while(0)

I am not an expert on gccbut it seems that gcc 3.4 eats do..while(0) loops (on i686)
We hat the discussion earlier in the ml. Your millage may vary since you are
crosscompiling. NTL if possible please post results for PPC.
BB will add an warning if this problem is on more that i686.

re,
 wh




More information about the busybox mailing list