Changeset 53770 in vbox for trunk/src/VBox/Additions/x11/vboxvideo
- Timestamp:
- Jan 12, 2015 9:10:36 AM (10 years ago)
- Location:
- trunk/src/VBox/Additions/x11/vboxvideo
- Files:
-
- 1 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/x11/vboxvideo/Makefile.kmk
r53570 r53770 103 103 vboxvideo_drv_SOURCES = \ 104 104 getmode.c \ 105 helpers.c \ 105 106 pointer.c \ 106 107 setmode.c \ -
trunk/src/VBox/Additions/x11/vboxvideo/getmode.c
r53624 r53770 141 141 unsigned i; 142 142 143 XF86ASSERT(cIndex < vboxNumStdModes,143 VBVXASSERT(cIndex < vboxNumStdModes, 144 144 ("cIndex = %d, vboxNumStdModes = %d\n", cIndex, 145 145 vboxNumStdModes)); -
trunk/src/VBox/Additions/x11/vboxvideo/vboxvideo.h
r53544 r53770 58 58 #ifdef DEBUG 59 59 60 #include <xf86.h>61 62 60 #define TRACE_ENTRY() \ 63 61 do { \ 64 xf86Msg(X_INFO,__PRETTY_FUNCTION__); \65 xf86Msg(X_INFO,": entering\n"); \62 vbvxMsg(__PRETTY_FUNCTION__); \ 63 vbvxMsg(": entering\n"); \ 66 64 } while(0) 67 65 #define TRACE_EXIT() \ 68 66 do { \ 69 xf86Msg(X_INFO,__PRETTY_FUNCTION__); \70 xf86Msg(X_INFO,": leaving\n"); \67 vbvxMsg(__PRETTY_FUNCTION__); \ 68 vbvxMsg(": leaving\n"); \ 71 69 } while(0) 72 70 #define TRACE_LOG(...) \ 73 71 do { \ 74 xf86Msg(X_INFO, __PRETTY_FUNCTION__); \75 xf86Msg(X_INFO,__VA_ARGS__); \72 vbvxMsg("%s: ", __PRETTY_FUNCTION__); \ 73 vbvxMsg(__VA_ARGS__); \ 76 74 } while(0) 77 75 # define TRACE_LINE() do \ 78 76 { \ 79 ErrorF ("%s: line %d\n", __FUNCTION__, __LINE__); \ 80 } while(0) 81 # define XF86ASSERT(expr, out) \ 82 if (!(expr)) \ 83 { \ 84 ErrorF ("\nAssertion failed!\n\n"); \ 85 ErrorF ("%s\n", #expr); \ 86 ErrorF ("at %s (%s:%d)\n", __PRETTY_FUNCTION__, __FILE__, __LINE__); \ 87 ErrorF out; \ 88 FatalError("Aborting"); \ 89 } 77 vbvxMsg("%s: line %d\n", __FUNCTION__, __LINE__); \ 78 } while(0) 90 79 #else /* !DEBUG */ 91 80 … … 93 82 #define TRACE_EXIT() do { } while (0) 94 83 #define TRACE_LOG(...) do { } while (0) 95 #define XF86ASSERT(expr, out) do { } while (0)96 84 97 85 #endif /* !DEBUG */ 86 87 /* Not just for debug builds. If something is wrong we want to know at once. */ 88 #define VBVXASSERT(expr, out) \ 89 if (!(expr)) \ 90 { \ 91 vbvxMsg("\nAssertion failed!\n\n"); \ 92 vbvxMsg("%s\n", #expr); \ 93 vbvxMsg("at %s (%s:%d)\n", __PRETTY_FUNCTION__, __FILE__, __LINE__); \ 94 vbvxMsg out; \ 95 vbvxAbortServer(); \ 96 } 98 97 99 98 #define BOOL_STR(a) ((a) ? "TRUE" : "FALSE") … … 234 233 } VBOXRec, *VBOXPtr; 235 234 235 /* helpers.c */ 236 extern void vbvxMsg(const char *pszFormat, ...); 237 extern void vbvxMsgV(const char *pszFormat, va_list args); 238 extern void vbvxAbortServer(void); 239 240 /* setmode.c */ 236 241 extern Bool vbox_init(int scrnIndex, VBOXPtr pVBox); 237 242 extern Bool vbox_cursor_init (ScreenPtr pScreen);
Note:
See TracChangeset
for help on using the changeset viewer.