This is the mail archive of the libc-help@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]

call a function even a program terminate abnormally


Hi,
I am wondering whether it is possible to invoke a function when a program
terminate abnormally (e.g., segfault). I know "atexit(3)" will do the job
if the process terminate normally. But I am wondering whether that is possible
for the abnormal case. Any system call for this (on Linux)?

I am doing some interprocess communication here. If a process just die with
a lock unlocked, there might be potential deadlock.

Thanks,
Yubin


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