Opened 13 years ago
Closed 13 years ago
#4055 closed defect (fixed)
OGR SQL: Crashes when evaluating SUBSTR with invalid offset/size, or with CAST() to invalid typename
Reported by: | Even Rouault | Owned by: | Even Rouault |
---|---|---|---|
Priority: | normal | Milestone: | 1.8.1 |
Component: | OGR_SF | Version: | 1.8.0 |
Severity: | normal | Keywords: | ogr sql substr cast |
Cc: |
Description
The following expressions cause a segfault :
ogrinfo ../autotest/ogr/data/poly.shp -sql "select substr(prfedea,-2100000000) from poly" ogrinfo ../autotest/ogr/data/poly.shp -sql "select substr(prfedea,0,-2100000000) from poly" ogrinfo ../autotest/ogr/data/poly.shp -sql "select substr(prfedea,0, cast(2 as int)) from poly"
Note:
See TracTickets
for help on using tickets.
r22270 /trunk/gdal/ogr/swq_op_general.cpp: OGR SQL: fix crashes when evaluating SUBSTR with invalid offset/size, or with CAST() to invalid typename (#4055)
r22271 /branches/1.8/gdal/ogr/swq_op_general.cpp: OGR SQL: fix crashes when evaluating SUBSTR with invalid offset/size, or with CAST() to invalid typename (#4055)