This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PR3498: more efficient dwfl searching


On 07/16/2009 11:01 AM, Frank Ch. Eigler wrote:
> I can't seem to reproduce this problem at all on my machine, but maybe
> this patch would work too.  The gist is to treat kern_dw[module]==0 as
> if kern_dw.find(module)==kern_dw.end().  IOW, if an erlier dwflpp()
> construction attempt failed via an exception, but the stl
> kern_dw[module] initialization already took place, then the resulting
> null pointer will be disregarded later.  Then a new attempt to run the
> dwflpp() ctor will be made (which may itself throw).

Ah yes, the initialization order is probably the culprit.  Another fix
would be to explicitly separate the new and map[] into separate
statements, but either way is fine.

Josh


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]