[mapserver-commits] r8879 - trunk/mapserver
svn at osgeo.org
svn at osgeo.org
Fri Apr 3 18:23:41 EDT 2009
Author: assefa
Date: 2009-04-03 18:23:41 -0400 (Fri, 03 Apr 2009)
New Revision: 8879
Modified:
trunk/mapserver/mapswf.c
Log:
SWF: test missing when creating EllipseButtons (#2966)
Modified: trunk/mapserver/mapswf.c
===================================================================
--- trunk/mapserver/mapswf.c 2009-04-03 22:20:05 UTC (rev 8878)
+++ trunk/mapserver/mapswf.c 2009-04-03 22:23:41 UTC (rev 8879)
@@ -1660,12 +1660,15 @@
psFillColor, psOutlineColor,
&sColorHighlightObj,
nLayerIndex, nShapeIndex, image);
- /* Ticket #2555 memory leak : need to store buttons to properly destroy them */
- StoreButton(oButton, image);
- oDisplay = _msSWFAddButtonWithId(image,
- GetCurrentMovie(map, image),
- oButton,
- nLayerIndex, nShapeIndex);
+ if (oButton)
+ {
+ /* Ticket #2555 memory leak : need to store buttons to properly destroy them */
+ StoreButton(oButton, image);
+ oDisplay = _msSWFAddButtonWithId(image,
+ GetCurrentMovie(map, image),
+ oButton,
+ nLayerIndex, nShapeIndex);
+ }
}
else
@@ -1679,11 +1682,14 @@
psFillColor, NULL,
&sColorHighlightObj,
nLayerIndex, nShapeIndex, image);
- StoreButton(oButton, image);
- oDisplay = _msSWFAddButtonWithId(image,
- GetCurrentMovie(map, image),
- oButton,
- nLayerIndex, nShapeIndex);
+ if (oButton)
+ {
+ StoreButton(oButton, image);
+ oDisplay = _msSWFAddButtonWithId(image,
+ GetCurrentMovie(map, image),
+ oButton,
+ nLayerIndex, nShapeIndex);
+ }
}
}
break;
More information about the mapserver-commits
mailing list