qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH 2/6] snapshot: add error set function


From: Wenchao Xia
Subject: Re: [Qemu-devel] [PATCH 2/6] snapshot: add error set function
Date: Fri, 21 Dec 2012 10:37:35 +0800
User-agent: Mozilla/5.0 (Windows NT 5.1; rv:16.0) Gecko/20121026 Thunderbird/16.0.2

于 2012-12-21 5:36, Eric Blake 写道:
On 12/16/2012 11:25 PM, Wenchao Xia wrote:
   Added two function which will try replace the error if it is
already set, so only last error is reported.


+#define error_setg_replace(err, fmt, ...) do {                     \
+    if (*err != NULL) { \
+        error_free(*err); \
+     } \
+    error_set(err, ERROR_CLASS_GENERIC_ERROR, fmt, ## __VA_ARGS__); \
+} while (/*CONSTCOND*/0)

qemu-queue.h is the only other file in qemu.git that uses /*CONSTCOND*/
notation, and that's because of the file origins; do we really need it here?

 OK, /*CONSTCOND*/ will be removed.

--
Best Regards

Wenchao Xia




reply via email to

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