mirror of https://git.48k.eu/ogserver
#559 fix out of bound array access
This patch change the size of the array ptrPar from 6 to 7. cppcheck says: [sources/ogAdmServer.cpp:598]: (error) Array 'ptrCfg[6]' accessed at index 6, which is out of bounds.master
parent
882fec820e
commit
3de93a9503
|
@ -534,7 +534,7 @@ bool actualizaConfiguracion(Database db, Table tbl, char *cfg, int ido)
|
||||||
{
|
{
|
||||||
char msglog[LONSTD], sqlstr[LONSQL];
|
char msglog[LONSTD], sqlstr[LONSQL];
|
||||||
int lon, p, c,i, dato, swu, idsoi, idsfi,k;
|
int lon, p, c,i, dato, swu, idsoi, idsfi,k;
|
||||||
char *ptrPar[MAXPAR], *ptrCfg[6], *ptrDual[2], tbPar[LONSTD];
|
char *ptrPar[MAXPAR], *ptrCfg[7], *ptrDual[2], tbPar[LONSTD];
|
||||||
char *ser, *disk, *par, *cpt, *sfi, *soi, *tam, *uso; // Parametros de configuración.
|
char *ser, *disk, *par, *cpt, *sfi, *soi, *tam, *uso; // Parametros de configuración.
|
||||||
|
|
||||||
lon = 0;
|
lon = 0;
|
||||||
|
|
Loading…
Reference in New Issue