Opened 16 years ago
Closed 16 years ago
#3133 closed bug (fixed)
Broken macro definition TRACE
Reported by: | Adek336 | Owned by: | axeld |
---|---|---|---|
Priority: | normal | Milestone: | R1 |
Component: | - General | Version: | R1/pre-alpha1 |
Keywords: | Cc: | ||
Blocked By: | Blocking: | ||
Platform: | All |
Description
patch
Index: MouseInputDevice.cpp =================================================================== --- MouseInputDevice.cpp (revision 28655) +++ MouseInputDevice.cpp (working copy) @@ -76,10 +76,10 @@ __FUNCTION__, sFunctionDepth) # define MID_CALLED(x...) FunctionTracer _ft(this, "MouseInputDevice", \ __FUNCTION__, sFunctionDepth) -# define TRACE(x...) { BString _to; \ +# define TRACE(x...) do { BString _to; \ _to.Append(' ', (sFunctionDepth + 1) * 2); \ debug_printf("%p -> %s", this, _to.String()); \ - debug_printf(x); } + debug_printf(x); } while(0) # define LOG_EVENT(text...) do {} while (0) # define LOG_ERR(text...) TRACE(text) #else
the current definition breaks build for when TRACE_MOUSE_DEVICE is enabled.
Similar problem is for add-ons/input_server/devices/keyboard/KeyboardInputDevice.cpp and perhaps more files.
Note:
See TracTickets
for help on using tickets.
Applied in hrev28656, thanks!