Opened 7 years ago

Closed 7 years ago

#5557 closed defect (duplicate)

CPLStringList::AddNameValue insert Value at wrong index

Reported by: oleinik Owned by: warmerdam
Priority: normal Milestone:
Component: GDAL_Raster Version: 1.11.0
Severity: normal Keywords:


I try to add next pairs Name/Value? to sorted CPLStringList "ScaleBounds?", "True" "ScaleBounds?.MinScale?", "0" "ScaleBounds?.MaxScale?", "2000000" As result I have List with next order of items: 1.ScaleBounds?.MaxScale?=2000000 2.ScaleBounds?.MinScale?=0 3.ScaleBounds?=True The third item "ScaleBounds?=True" in sorted list must be at fist position. Due to wrong order of items FindName? method for Name="ScaleBounds?" return -1 and moreover then I can add several items with Name="ScaleBounds?" to sorted CPLStringList

Change History (1)

comment:1 Changed 7 years ago by Even Rouault

Resolution: duplicate
Status: newclosed

Hum, yes I actually hit that a few days ago. So closing this one as a duplicate of #5540

Note: See TracTickets for help on using tickets.