mirror of
https://github.com/gryf/wmaker.git
synced 2026-01-09 15:24:12 +01:00
WINGs: Removed cast to change function prototype
When a function is used as a call-back, it is dangerous to have arguments with a type different than what is expected by the call-back definition. This patch sets the argument list to match what is expected by the call-back prototype and inserts an explicit type conversion at the beginning of the function.
This commit is contained in:
committed by
Carlos R. Mafra
parent
bab90b2168
commit
e2d816c7a2
@@ -52,7 +52,7 @@ static void defaultHandler(int bla)
|
||||
exit(1);
|
||||
}
|
||||
|
||||
static waborthandler *aborthandler = (waborthandler *) defaultHandler;
|
||||
static waborthandler *aborthandler = defaultHandler;
|
||||
|
||||
#define wAbort(a) (*aborthandler)(a)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user