qemu-devel
[Top][All Lists]
Advanced

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

[Qemu-devel] [PATCH 09/10] ssd0323: abort() instead of exit(1) on error.


From: Peter Maydell
Subject: [Qemu-devel] [PATCH 09/10] ssd0323: abort() instead of exit(1) on error.
Date: Mon, 13 Aug 2012 16:31:58 +0100

From: "Peter A. G. Crosthwaite" <address@hidden>

To be more consistent with the newer ways of error signalling. That and SIGABT
is easier to debug with than exit(1).

Signed-off-by: Peter A. G. Crosthwaite <address@hidden>
Reviewed-by: Peter Maydell <address@hidden>
Signed-off-by: Peter Maydell <address@hidden>
---
 hw/ssd0323.c |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/hw/ssd0323.c b/hw/ssd0323.c
index b0b2e94..b101c51 100644
--- a/hw/ssd0323.c
+++ b/hw/ssd0323.c
@@ -19,7 +19,9 @@
 #define DPRINTF(fmt, ...) \
 do { printf("ssd0323: " fmt , ## __VA_ARGS__); } while (0)
 #define BADF(fmt, ...) \
-do { fprintf(stderr, "ssd0323: error: " fmt , ## __VA_ARGS__); exit(1);} while 
(0)
+do { \
+    fprintf(stderr, "ssd0323: error: " fmt , ## __VA_ARGS__); abort(); \
+} while (0)
 #else
 #define DPRINTF(fmt, ...) do {} while(0)
 #define BADF(fmt, ...) \
-- 
1.7.9.5




reply via email to

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