From: Jens Axboe Date: Tue, 13 Feb 2007 19:09:10 +0000 (+0100) Subject: [PATCH] Make fio_assert() core dump the job X-Git-Tag: fio-1.12~91 X-Git-Url: https://git.kernel.dk/?p=fio.git;a=commitdiff_plain;h=340fd243a168d881dd80b45f2ffb424287db8b7e [PATCH] Make fio_assert() core dump the job Signed-off-by: Jens Axboe --- diff --git a/fio.h b/fio.h index c15232a2..b420db5a 100644 --- a/fio.h +++ b/fio.h @@ -672,10 +672,11 @@ extern void close_ioengine(struct thread_data *); #define fio_assert(td, cond) do { \ if (!(cond)) { \ + int *__foo = NULL; \ fprintf(stderr, "file:%s:%d, assert %s failed\n", __FILE__, __LINE__, #cond); \ (td)->runstate = TD_EXITED; \ (td)->error = EFAULT; \ - exit(0); \ + *__foo = 0; \ } \ } while (0)