This is the mail archive of the libc-alpha@sources.redhat.com 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] |
Hi Kaz, > What if your process crashes? What if something calls exit() and blows > away all threads, or, equivalently, the main thread returns from the > main function? > > The TSD cleanup mechanism does not ensure that the functions are called > no matter how the process terminates, so you can't rely on it for > fail-safe cleanup of persistent resources. I never said I want a fail-safe cleanup. The spec never said that I shouldn't use TSD destructors for releasing non-local resources. Spec just said that at thread exit the TSD destructors are called. I am free to use them no matter how stupid it may sound. Thus you cannot decide for me. BTW, one reason why you may want to release even process-local resources is to keep memory checkers calm. hth, -boris
Attachment:
signature.asc
Description: Digital signature
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |