Remove cast on void pointers. C programming language guarantees
the conversion from void pointer to any other pointer type.
Coccinelle patch:
@r@
expression x;
void* e;
type T;
identifier f;
@@
(
*((T *)e)
|
((T *)x)[...]
|
((T *)x)->f
|
- (T *)
e
)
Signed-off-by: Alison Schofield <amsfield22@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
return result;
}
- ptstrJoinBssParam = (struct join_bss_param *)pstrHostIFconnectAttr->params;
+ ptstrJoinBssParam = pstrHostIFconnectAttr->params;
if (!ptstrJoinBssParam) {
PRINT_ER("Required BSSID not found\n");
result = -ENOENT;
{
u32 u32Ret;
struct host_if_msg msg;
- struct wilc *wilc = (struct wilc*)pvArg;
+ struct wilc *wilc = pvArg;
struct wilc_vif *vif;
memset(&msg, 0, sizeof(struct host_if_msg));