This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc 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: fix audit testcase with IE TLS disabled


> As explained in the comment below, if we relocate ldso before setting
> up TLS, the calloc call at the end of the self relocation will either
> use uninitialized TLS (if libc uses IE) or crash because __tls_get_addr
> returns NULL.

The analysis makes sense to me and the fix seems right.  But it is a subtle
issue and I feel better if there is a concrete test case to verify.  I
realize this has sat for a long time.  When I spent the time to think about
it, it seemed straightforward (to me, but then I wrote the dynamic linker).
But until I was ready to spend the time to focus on it, it wasn't clear how
clear it would be.  It only took me a few minutes to write a test case that
readily demonstrates the bug, based directly on your description of the
scenario.  I think this would have had a greatly better chance of getting
dealt with sooner if you had included a patch to add a test case like the
one I've just put in.  Also, please include complete standard header lines
in your log entries.  Finally, the best way we have for making sure things
don't fall on the floor is bugzilla; I had your message sitting for months
in a mail folder knowing I had to look at it one day, but that's not
reliable.  

Ideal form is to file a bugzilla report, include a test case in the form of
a patch to add one to libc's test suite along with your fix, put the
bugzilla number in your ChangeLog entries in [BZ #nnn] style as you can see
in the file, and post it with the BZ# also in the subject line.  Of course,
manpower to sift through bug reports and proposed patches is what really
determines whether your patch sits for months or gets processed quickly.
But taking all these steps gives you the best chance that I can immediately
tell that it will be quick for me to evaluate the change, and will give it
a little quick attention rather than just going on the long queue.


Thanks,
Roland


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