X-Git-Url: http://git.vrable.net/?a=blobdiff_plain;ds=sidebyside;f=TBBT%2Ftrace_play%2Frfs_assert.h;fp=TBBT%2Ftrace_play%2Frfs_assert.h;h=ec360d51ef5d747ff98b901b374e2bc080f1ad9b;hb=adc8816a09e5b6be2e58f4a7c28d2418a74cce9c;hp=0000000000000000000000000000000000000000;hpb=145b4756946bbd443452ec1b2081984795de70d0;p=bluesky.git diff --git a/TBBT/trace_play/rfs_assert.h b/TBBT/trace_play/rfs_assert.h new file mode 100644 index 0000000..ec360d5 --- /dev/null +++ b/TBBT/trace_play/rfs_assert.h @@ -0,0 +1,13 @@ +#ifndef RFS_ASSERT_H +#define RFS_ASSERT_H +#define RFS_ASSERT(condition) \ + if (!(condition)) { \ + fprintf(stderr, "Assertion failed: line %d, file \"%s\"\n", \ + __LINE__, __FILE__); \ + fflush(stdout); \ + fflush(stdout); \ + fflush(stderr); \ + fflush(stderr); \ + exit(-1); \ + } +#endif