[mapserver-users] seg faults with php_mapscript

Nicol Hermann nicol.hermann at geoworld.de
Tue Nov 20 15:55:52 EST 2001


Dear List,

i´m working with the latest build of mapserver and php_mapscript on SuSE
Linux (2.4.12) with PHP 4.0.6 (build as module) and mysql (3.23.41).

To create the map i dynamically get the layer information from the mysql
database where each parameter is stored in a separate field. 

To ensure that the variables for example 'units' has the right type i
convert it if needed into Integer. After that i check the transformation
with

settype($map_units, "Integer");	
printf ('<br>Units: %s', var_dump($map_units) );

printf returns int(5)

Now my problem starts. Whenever i use this variable '$map_units' in the
statement 
$map -> scalebar -> set ("units", $map_units);
it causes a Segmentation fault. If i replace the variable '$map_units'
with a "true" value for example 5 ( $map -> scalebar -> set ("units",
5); ) the application works fine.

Does anybody know what´s the problem?
Thanks for any help.

Greetings from Germany
Nicol



More information about the mapserver-users mailing list