cvs commit: src/sys/kern vfs_mount.c

Poul-Henning Kamp phk at
Wed Nov 9 07:01:40 GMT 2005

In message <43716BD6.5050604 at>, Nate Lawson writes:

>While I don't have ideas for a better general mechanism for this, I 
>think it sets a bad precedent.  We can't have every complex syscall 
>transporting its own error message strings back to the user program. 
>And we can't expand errno to be the union of every single API-specific 
>error either.

That was one the main points of my ioctl talk at BSDcan.

One way to solve it:

Hang a sbuf pointer in each thread and APIs cound stuff their error
message there.

Add a new syscall to return the string to userland.

Modify perror(3), err(3) and similar to pull out the "extended"
error, if there is one.

Poul-Henning Kamp       | UNIX since Zilog Zeus 3.20
phk at FreeBSD.ORG         | TCP/IP since RFC 956
FreeBSD committer       | BSD since 4.3-tahoe    
Never attribute to malice what can adequately be explained by incompetence.

More information about the cvs-src mailing list