mirror of
https://github.com/qgis/QGIS.git
synced 2025-03-01 00:46:20 -05:00
Avoid string overflow
This commit is contained in:
parent
153dea25e4
commit
e6f91ca4b2
@ -613,7 +613,9 @@ bool QgsSpatiaLiteConnection::isRasterlite1Datasource( sqlite3 * handle, const c
|
||||
char table_raster[4192];
|
||||
char sql[4192];
|
||||
|
||||
strcpy( table_raster, table );
|
||||
strncpy( table_raster, table, 4192 );
|
||||
table_raster[4191] = '\0';
|
||||
|
||||
len = strlen( table_raster );
|
||||
if ( strlen( table_raster ) < 9 )
|
||||
return false;
|
||||
|
Loading…
x
Reference in New Issue
Block a user