Opened 17 years ago
Closed 17 years ago
#2194 closed defect (fixed)
Use of uninitialised value in msCopySymbol()
Reported by: | dmorissette | Owned by: | dmorissette |
---|---|---|---|
Priority: | normal | Milestone: | 5.0 release |
Component: | MapServer C Library | Version: | 5.0 |
Severity: | normal | Keywords: | |
Cc: |
Description
Running valgrind on the 'testcopy' program (compile it using make testcopy) reported:
==22437== Use of uninitialised value of size 8 ==22437== at 0x808396F: msCopySymbol (mapsymbol.c:950) ==22437== by 0x8083CC8: msCopySymbolSet (mapsymbol.c:1013) ==22437== by 0x807279C: msCopyMap (mapcopy.c:888) ==22437== by 0x804CB92: main (testcopy.c:59)
Note:
See TracTickets
for help on using tickets.
This was caused by the loop that copies points[] in msCopySymbol() that should copy only src->numpoints points instead of attempting to copy MS_MAXVECTORPOINTS points.
The same issue was present in the loop that copies symbol patterns in the same fuction.
Fixed in r6442.