[parted-devel] BUG: ped_exception_throw() can go to endless loop allocating memory
petr.uzel at suse.cz
Tue Feb 10 11:00:57 UTC 2009
On Tue, Feb 10, 2009 at 05:44:20AM -0500, Joel Granados wrote:
> > in the while will do the same thing as the NULL. Additionally, I
> > don't see any other place where it is modified in the function before
> > getting to line 243, where it is called with the 0 value.
> > >
> > > Am I missing something?
> > No, you are not, but obviously I am.
> > Let me start from scratch and let's forget what I wrote before as
> > there were too many mistakes :)
> > About three moths ago, I was debugging parted on s390 - it went into
> > endless loop allocating memory. I'm pretty sure that this happened
> > inside the ped_exception_throw() function, which was called with
> > weird
> > arguments (from mentioned dasd.c:243). Removing this call (as it does
> > not provide any useful information anyway) fixed it.
> mmm. interesting. I'll try to test with what we have in the office. In any case, if you encounter this again, it would be *great* to have a test case.
It would, but I'm afraid I won't get access to that s390 beast anytime soon :(
> > But obviously I was wrong with the ped_exception_throw() analysis -
> > as
> > you correctly noted:
> > 1) ped_exception_throw() is called with message==NULL==0 in
> > dasd.c:243
> > 2) in ped_exception_throw(), if message==NULL, it shouldn't go into
> > the while loop at all.
> > But I'm pretty sure it went into that loop. The problem is that I
> > have
> > no longer access to that s390 machine where this was easily
> > reproduced. Looking into the ped_exception_throw() code it is not
> > clear to me what actually happened there: the only thing that comes
> > to
> > my mind now is that the function can be called with variadic
> > arguments, but these are missing - can this make any troubles on s390
> > (IMHO it is OK on more common architectures) ?
> > I'm really confused now.
> > Thanks to Joel for correcting me and apologies for the noise here.
> In any case, I think there is still something to rescue from this issue and it is the lack of an error message. I will post a patch adding one. hopefully today.
Best regards / s pozdravem
Petr Uzel, Packages maintainer
SUSE LINUX, s.r.o. e-mail: puzel at suse.cz
Lihovarská 1060/12 tel: +420 284 028 964
190 00 Prague 9 fax: +420 284 028 951
Czech Republic http://www.suse.cz
More information about the parted-devel