<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii">
<TITLE>Messaggio</TITLE>
<META content="MSHTML 6.00.2900.2523" name=GENERATOR></HEAD>
<BODY>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>Hi
list,</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>I use CGI MapServer
4.2.3 on a RH9 with Apache 2.0.50:</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN
class=988341312-06122004></SPAN></FONT> </DIV>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004><!-- MapServer
version 4.2.3 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP OUTPUT=PDF
SUPPORTS=FREETYPE INPUT=EPPL7 INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE
--><BR></SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>All works, but I
have a map that returns an "Internal Server Error" when I try to zoom and show a
certain extent with a specific layer.</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>I think the problem
is due to the shapefile (or a part of it), but... how can I be sure of
it?</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN
class=988341312-06122004></SPAN></FONT> </DIV>
<DIV><FONT face=Arial size=2><SPAN
class=988341312-06122004></SPAN></FONT> </DIV>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>The browser only
show the "Internal Server Error" page.</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>The Apache error log
says: "[Mon Dec 06 07:13:04 2004] [error] [client 172.16.20.4] Premature end of
script headers: mapserv"</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN
class=988341312-06122004></SPAN></FONT> </DIV>
<DIV><FONT face=Arial size=2><SPAN
class=988341312-06122004></SPAN></FONT> </DIV>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>I compiled MapServer
with --enable-debug, set "DEBUG TRUE" in the map section of the mapfile,
and tried to use shp2img with these results:</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>----------<SPAN
class=988341312-06122004>----------<SPAN
class=988341312-06122004>----------<SPAN
class=988341312-06122004>----------<SPAN
class=988341312-06122004>----------<SPAN
class=988341312-06122004>----------<SPAN
class=988341312-06122004>----------<SPAN
class=988341312-06122004>------</SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>[root@redhat cs]#
/dati/geobase/bin/shp2img -m cs.map -o /dati/daniele.png -e 2491361 4510665
2492415 4511455<BR>[Mon Dec 6 07:24:37 2004].748031 msDrawMap(): Layer 0
(Confini_comunali), 0.040s<BR>[Mon Dec 6 07:24:41 2004].893212
msDrawMap(): Layer 1 (Base_cartografica), 4.145s<BR>[Mon Dec 6 07:24:41
2004].908452 msDrawMap(): Layer 2 (Edifici), 0.015s<BR>[Mon Dec 6 07:24:41
2004].918383 msDrawMap(): Layer 3 (Aree_traffico), 0.010s<BR>Segmentation
fault</SPAN></FONT></DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>----------<SPAN
class=988341312-06122004>----------<SPAN
class=988341312-06122004>----------<SPAN
class=988341312-06122004>----------<SPAN
class=988341312-06122004>----------<SPAN
class=988341312-06122004>----------<SPAN
class=988341312-06122004>----------<SPAN
class=988341312-06122004>------</SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></FONT></DIV>
<DIV></SPAN></FONT><FONT face=Arial size=2><SPAN
class=988341312-06122004>[root@redhat cs]# /dati/geobase/bin/shp2img -m cs.map
-o /dati/daniele.png -e 2491361 4510665 2492415 4511455 -l
Elementi_stradali<BR>Segmentation fault<BR></DIV>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>----------<SPAN
class=988341312-06122004>----------<SPAN
class=988341312-06122004>----------<SPAN
class=988341312-06122004>----------<SPAN
class=988341312-06122004>----------<SPAN
class=988341312-06122004>----------<SPAN
class=988341312-06122004>----------<SPAN
class=988341312-06122004>------</SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004><SPAN
class=988341312-06122004><SPAN class=988341312-06122004><SPAN
class=988341312-06122004><SPAN class=988341312-06122004><SPAN
class=988341312-06122004><SPAN class=988341312-06122004><SPAN
class=988341312-06122004></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></SPAN></FONT> </DIV>
<DIV></SPAN></FONT><FONT face=Arial size=2><SPAN class=988341312-06122004>When
shp2img processes the "bad" layer ('Elementi_stradali'), it exits with a
'Segmentation fault' and without a more explicit error
message.</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN
class=988341312-06122004></SPAN></FONT> </DIV>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>I launched
the following command (<FONT face=Arial size=2><SPAN
class=988341312-06122004>where "road_elements.shp" is the probably bad
shapefile):</SPAN></FONT></SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>[root@redhat
cat_strade]# ogrinfo -al road_elements.shp -spat 2491361 4510665 2492415
451145</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN
class=988341312-06122004></SPAN></FONT> </DIV>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>It returns a 85 Kb
output with apparently no detected errors.</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN
class=988341312-06122004></SPAN></FONT> </DIV>
<DIV><FONT face=Arial size=2><SPAN
class=988341312-06122004></SPAN></FONT> </DIV>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>How can I understand
where the error lies?</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>Is there a more
powerful debug tool?</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN
class=988341312-06122004></SPAN></FONT> </DIV>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>Thank
you,</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN class=988341312-06122004>
Daniele</SPAN></FONT></DIV>
<DIV><FONT face=Arial size=2><SPAN
class=988341312-06122004> </DIV></SPAN></FONT></BODY></HTML>