[Top][All Lists]

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

Re: [Qemu-devel] [PATCH] error: error_setg_errno(): errno gets preserved

From: Markus Armbruster
Subject: Re: [Qemu-devel] [PATCH] error: error_setg_errno(): errno gets preserved
Date: Wed, 27 Jul 2016 13:02:49 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux)

Sascha Silbe <address@hidden> writes:

> C11 allows errno to be clobbered by pretty much any library function
> call, so in general callers need to take care to save errno before
> calling other functions.
> However, for error reporting functions this is rather awkward and can
> make the code on the caller side more complicated than
> necessary. error_setg_errno() already takes care of preserving errno
> and some functions rely on that, so just promise that we continue to
> do so in the future.
> Signed-off-by: Sascha Silbe <address@hidden>

Reviewed-by: Markus Armbruster <address@hidden>

reply via email to

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