mirror of
https://github.com/alliedmodders/amxmodx.git
synced 2025-01-13 23:38:07 +03:00
Am I wrong or should this be this way to prevent security bugs?
This commit is contained in:
parent
ca70678155
commit
a46ec5357e
@ -176,7 +176,7 @@ static cell AMX_NATIVE_CALL console_cmd(AMX *amx, cell *params) /* 2 param */
|
|||||||
CPlayer* pPlayer = GET_PLAYER_POINTER_I(index);
|
CPlayer* pPlayer = GET_PLAYER_POINTER_I(index);
|
||||||
|
|
||||||
if (!pPlayer->bot && pPlayer->initialized)
|
if (!pPlayer->bot && pPlayer->initialized)
|
||||||
CLIENT_COMMAND(pPlayer->pEdict, UTIL_VarArgs("%s", cmd));
|
CLIENT_COMMAND(pPlayer->pEdict, "%s", cmd);
|
||||||
}
|
}
|
||||||
|
|
||||||
return len;
|
return len;
|
||||||
@ -1403,7 +1403,7 @@ static cell AMX_NATIVE_CALL client_cmd(AMX *amx, cell *params) /* 2 param */
|
|||||||
{
|
{
|
||||||
CPlayer* pPlayer = GET_PLAYER_POINTER_I(i);
|
CPlayer* pPlayer = GET_PLAYER_POINTER_I(i);
|
||||||
if (!pPlayer->bot && pPlayer->initialized /*&& pPlayer->ingame*/)
|
if (!pPlayer->bot && pPlayer->initialized /*&& pPlayer->ingame*/)
|
||||||
CLIENT_COMMAND(pPlayer->pEdict, UTIL_VarArgs("%s", cmd));
|
CLIENT_COMMAND(pPlayer->pEdict, "%s", cmd);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
int index = params[1];
|
int index = params[1];
|
||||||
@ -1417,7 +1417,7 @@ static cell AMX_NATIVE_CALL client_cmd(AMX *amx, cell *params) /* 2 param */
|
|||||||
CPlayer* pPlayer = GET_PLAYER_POINTER_I(index);
|
CPlayer* pPlayer = GET_PLAYER_POINTER_I(index);
|
||||||
|
|
||||||
if (!pPlayer->bot && pPlayer->initialized /*&& pPlayer->ingame*/)
|
if (!pPlayer->bot && pPlayer->initialized /*&& pPlayer->ingame*/)
|
||||||
CLIENT_COMMAND(pPlayer->pEdict, UTIL_VarArgs("%s", cmd));
|
CLIENT_COMMAND(pPlayer->pEdict, "%s", cmd);
|
||||||
}
|
}
|
||||||
|
|
||||||
return len;
|
return len;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user