C != Java
Which is to say, a null pointer is not a valid argument to unlink, and the Hurd's use of a signal instead of an error is allowed by Posix.
I've been looking at the problems with visudo as tracked on alioth.
I've applied Justus's fix to use flock instead of lockf, and created a
patch that solves the segfault issue (see attached). visudo now seems
to work correctly on Hurd.
However, I'm uncertain whether the segfault should actually be
considered a bug in visudo, or whether it should rather be fixed in
Hurd's implementation of unlink (see backtrace). As such, I'm asking
on the list for advice before I submit this as a bug report. (I'll be
submitting Justus's fix anyway, as it's really a separate problem.)
As you can see in the attached patch, visudo already uses a void cast
on unlink, suggesting that it doesn't care if the unlink operation
fails. Presumably on Linux and kFreeBSD (I haven't verified this, as
I'm not sure where it's defined), unlink exits gracefully with failure
if it is passed a null pointer, whereas on Hurd it doesn't check this
and segfaults as a result.
Is this something that should be fixed in Hurd (or perhaps eglibc), or
should I go ahead and submit the attached patch via the BTS?