This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos 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: Possible bug in dbg-threads-syscall.c


Patrick Doyle wrote:
> 
> I believe that I have found a subtle bug in "dbg-threads-syscall.c", and I
> would appreciate some feedback on this.
> 
> Here is the 'dbg_thread_syscall()' function.  The problem is that, on the
> surface, this looks correct, but in my particular environment, where
> 'dbg_thread_syscall()' is called when 'dbg_syscall_ptr' is NULL, things just
> don't work.

We haven't noticed that before, so I wonder what's different in your
environment? Oh, perhaps it only happens if you're trying to debug before
the kernel runs its constructors.
 
> Anyway, here is my proposed patch, comments and feedback are definately
> welcome :-)

Looks fine, although I left in the check for *f being non-NULL too. It's
good defensive programming anyway.

Jifl
-- 
Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062
Maybe this world is another planet's Hell -Aldous Huxley || Opinions==mine


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