[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [LTP] New stat() test cases, please comment
On Wed, Mar 07, 2001 at 09:31:11AM -0800, Wayne Boyer wrote:
> I ran into this very problem with a test program that I wrote for the
> shmdt () call. The test purposely has an assignment statement that
I ran into that syscall while trying to port more test cases. I also
have sigaction(), gethostname(), adjtime(), and utime() on the list.
I'm sure there are more.
> will cause a SIGSEGV to be generated. Like you, I found that handling
> SIGSEGV is tricky. After talking with some other engineers, I choose
> to use the sigsetjmp() and siglongjmp() calls in much the same way
> that you are using setjmp() and longjmp(). The former two allow
Did they have any concerns. This looks like an ugly hack to several
people I've spoken to. It seems to work, but I'm concerned that it
> The bottom line is that I believe the use of these calls is an
> acceptable way to handle SIGSEGV in an interal signal handling
It's still a shame that we have to do it this way. IMHO, glibc needs to
handle the SIGSEGV itself and return EFAULT like the syscall is supposed
to. It's not going to be an easy fight.
Nate Straz email@example.com
sgi, inc http://www.sgi.com/
Linux Test Project http://oss.sgi.com/projects/ltp/