[Mapserver-users] php.exe crash with drawQuery

W. Steph chewbizz at hotmail.com
Tue Jul 29 03:43:14 EDT 2003


First, thank you for the marker bug. But I can't compile mapscript myself 
(not ennough HD space and not enough time to set up the compiling 
envirronment and deal with problems)... I will probably wait until there's a 
compiled release.

For the drawQuery bug : I investigated a bit more and I think I've found the 
problem. You were right, that's not a mapScript problem; it seems to be a 
data problem.
A few weeks ago, I was testing the response time of my web application, so I 
decided to quadruplate each raw in a PostGis table (changing only the GID). 
That seems to be the cause of the php.exe crash. But I don't know why ! 
(maybe mapserver doesn't like to have equals geometries in the same postgis 
table ?)

Now, with all raws having its own geometry (and not a copy of of other raw's 
geometry) I still have a problem :
When querying a too large number of shapes (>35) with queryByRect, php keeps 
working without stopping, even after the time limit ! (I'm using 
set_time_limit(60);) and the problem is still with drawQuery() because the 
query is ok, and the returned shape list is ok.

That's definitely a weird behaviour, but it's not really too much annoying.
I know I'm not giving precise information about the problem, but if it can 
help to find it....
If I find more clues about it (or another bug), I'll post a mail.

Regards
Steph

>From: Daniel Morissette <morissette at dmsolutions.ca>
>To: "W. Steph" <chewbizz at hotmail.com>
>CC: Mapserver-users at lists.gis.umn.edu
>Subject: Re: [Mapserver-users] php.exe crash with drawQuery
>Date: Mon, 28 Jul 2003 10:57:22 -0400
>
>Steph,
>
>DrawQuery() works for me in all the tests that I make on both Windows and 
>Linux.  I also ran a sequence of Query + DrawQuery() with Valgrind (a 
>memory checker) and no errors were reported.
>
>So it must be something specific to your data, mapfile or script.  If you 
>can then please file a bug in bugzilla and attach a small reproduceable 
>test case (script, mapfile and data).  Otherwise I don't think anyone can 
>help without a way to reproduce the problem.
>
>BTW, the reference map marker problem (bug 378) is fixed in the 4.0 CVS.
>
>Daniel
>
>
>W. Steph wrote:
>
>>Hello again !
>>
>>I have a problem with $map->drawQuery() with mapscript 4 : here is my 
>>php-mapscript code :
>>[$queryzone = ..]
>>if ($queryselectmode == "clic")
>>{
>>  $success=@$qlay->queryByPoint($queryzone,MS_MULTIPLE,-1);
>>}
>>else
>>{
>>  $success=@$qlay->queryByRect($queryzone);
>>}
>>if ($success==MS_SUCCESS)
>>{
>>  for ($o=0; $o<$qlay->getNumResults(); $o++)
>>  {
>>    $rcmo = $qlay->getResult($o);
>>    $queryresults[$qlay->name][$o] = $rcmo->shapeindex;
>>  }
>>  $querysucceed=true;
>>}
>>[...]
>>if ($querysucceed)
>>{
>>  $querymap = $map->drawQuery();
>>  $querymapimg = $querymap->SaveWebImage(MS_JPG,1,1,$quality);
>>}
>>
>>This code makes php.exe crash on the line $querymap = $map->drawQuery(); 
>>(with querybypoint _and_ querybyrect) with numerous different test cases.
>>But it worked with previous versions...
>>I found in the mapServer Wikki that there where MapFiles changes in 4.0, 
>>and I saw ITEMQUERY and ITEMNQUERY : I don't have these in my mapfile, and 
>>I don't know what they are used for (I found nothing about it in the 
>>mapFile reference). Maybe my problem could be solved with this ? Also, I 
>>didn't change anything in my mapfiles since I use mapserver 4.0; maybe 
>>there are other things to do but I can't understand everything very well 
>>on the wikki's migration guide.
>>Can somebody help ?
>>
>>Thanks a lot
>>Steph
>>
>
>

_________________________________________________________________
MSN Messenger 6  http://g.msn.fr/FR1001/866 : plus de personnalisation, plus 
de fun pour vous et vos amis…




More information about the mapserver-users mailing list