[mapserver-users] Expression segmentation fault
Frank Broniewski
brfr at metrico.lu
Wed Sep 4 05:25:30 PDT 2013
Hi,
I just updated my mapserver installation to the latest version (6.2.1).
I'm running FreeBSD 9.1 and I'm getting a segmentation fault related to
expression usage in my mapfile. I've already compiled mapserver with
debug symbols and I loaded the core file into gdb:
> gdb /usr/local/www/apache22/cgi-bin/mapserv mapserv.core
<snip>
Reading symbols from /lib/libc.so.7...done.
Loaded symbols for /lib/libc.so.7
Reading symbols from /usr/local/lib/libintl.so.9...done.
Loaded symbols for /usr/local/lib/libintl.so.9
Reading symbols from /usr/lib/libsupc++.so.1...done.
Loaded symbols for /usr/lib/libsupc++.so.1
Reading symbols from /libexec/ld-elf.so.1...done.
Loaded symbols for /libexec/ld-elf.so.1
#0 0x00000008008e2520 in yylex (lvalp=0x7fffffffd250, p=0x7fffffffd3b0)
at mapparser.y:649
649 mapparser.y: No such file or directory.
in mapparser.y
[New Thread 809007400 (LWP 101134/mapserv)]
So apparently there seems to be a file missing!? Looking at the source
code (git), line 649 is a blank line, so I'm not sure what's missing
exactly. I've got yacc, bison and flex installed. For testing purposes
I'm using the mapserver cgi on the command line:
/usr/local/www/apache22/cgi-bin/mapserv -nh
"QUERY_STRING=map=/data/web/mapserver/cnra/cnra.map&mode=map&layer=boundaries"
The boundaries layer:
Layer
# Classitem "level"
Connection "host=10.0.0.2 dbname=osm user=user password=guessme"
Connectiontype Postgis
Data "geom FROM (SELECT osm_id, way AS geom, name, admin_level AS
level, tags FROM planet_osm_polygon) AS foo USING UNIQUE osm_id USING
SRID=3857"
Filter "tags ?& ARRAY['boundary', 'admin_level']"
Name "boundaries"
Processing "CLOSE_CONNECTION=DEFER"
Status on
Type line
Units meters
Metadata
"ows_title" "Boundary Map"
"ows_abstract" "Boundary map - data from OpenStreetMap, ODbl
licensed"
End
Projection
"init=epsg:3857"
End
Class
Expression ("[level]" = "6")
# Expression "6"
Name "communes"
Style
Color 10 10 10
Opacity 50
Width 2
End
End
End
The classitem / simple expression (Expression "6") works with the
mapserver cgi, but python mapscript throws an error:
_mapscript.MapServerError: msEvalExpression(): General error message.
Invalid item index.
I've read the mapserver expressions documentation [1] and the note that
says something about the working environment might be linked to more
than one expression library. But my operating system skills are not high
enough to turn this paragraph into something useful for me.
So any help is greatly appreciated.
Frank
Frank BRONIEWSKI
METRICO s.à r.l.
géomètres
technologies d'information géographique
rue des Romains 36
L-5433 NIEDERDONVEN
tél.: +352 26 74 94 - 28
fax.: +352 26 74 94 99
http://www.metrico.lu
More information about the MapServer-users
mailing list