1 /* This file is part of the Project Athena Zephyr Notification System.
2 * It is one of the source files comprising zwgc, the Zephyr WindowGram
5 * Created by: Marc Horowitz <marc@athena.mit.edu>
7 * $Id: error.h 2493 2009-07-13 05:17:23Z kcr@ATHENA.MIT.EDU $
9 * Copyright (c) 1989 by the Massachusetts Institute of Technology.
10 * For copying and distribution information, see the file
15 #include <zephyr/mit-copyright.h>
22 #include <zephyr/zephyr.h>
24 extern int error_code;
26 #define FATAL_TRAP(function_call, message) \
27 { error_code = (function_call);\
29 com_err("zwgc", error_code,\
35 #define TRAP(function_call, message) \
36 { error_code = (function_call);\
38 com_err("zwgc", error_code,\
43 #define ERROR(a) { fprintf(stderr, "zwgc: "); \
47 #define ERROR2(a,b) { fprintf(stderr, "zwgc: "); \
48 fprintf(stderr, a, b);\
51 #define ERROR3(a,b,c) { fprintf(stderr, "zwgc: "); \
52 fprintf(stderr, a, b, c);\
55 #define ERROR4(a,b,c,d) { fprintf(stderr, "zwgc: "); \
56 fprintf(stderr, a, b, c, d);\