qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [6324] Return -errno on write failure (Gleb Natapov)


From: François Revol
Subject: Re: [Qemu-devel] [6324] Return -errno on write failure (Gleb Natapov)
Date: Thu, 15 Jan 2009 23:33:57 +0100 CET

> In message: <address@hidden>
>             "François Revol" <address@hidden> writes:
> : > Revision: 6324
> : >           http://svn.sv.gnu.org/viewvc/?view=rev&root=qemu&revision=6324
> > : > > Author:   aliguori
> : > Date:     2009-01-15 20:44:26 +0000 (Thu, 15 Jan 2009)
> : >
> : > Log Message:
> : > -----------
> : > Return -errno on write failure (Gleb Natapov)
> :
> : Nooooooooooo
> : Please do not this bad broken Unix habit!
>
> s/Unix/Linux/

I didn't want to sound inquisitory, but indeed most uses I've seen come
from Linux code or linux devs, though OSSv4 had it quite everywhere.

It's actually fairly common inside Unix kernels themselves.
There it's absolutely no problem since it's by definition code that
only targets a single OS. But I've seen more and more userland (and
portable kernel) code using this bad trick without consideration for
other platforms.

The fact that it's "standardized" doesn't make it better for real world
implementations that do depart from the standard.
And Opengroup screwing up didn't help:
http://www.opengroup.org/onlinepubs/000095399/basedefs/errno.h.html#tag_13_10_10

I'll try to make a patch to correct this.

François.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]