[GRASS-dev] native WinGRASS and attribute data deadlock, next try

Glynn Clements glynn at gclements.plus.com
Tue Sep 18 15:38:19 EDT 2007


Moritz Lennert wrote:

> I have tried to get some more debug output for the wingrass db deadlock
> problem. I started from Benjamin's work, and tried to apply Glynn's
> suggestions. I have to admit, though, that I still do not completely
> understand xdr, so I'm not sure if what I did makes sense.
> 
> In order to not have different debug outputs mingle, I had to create 8 log
> files, one for each function and for each stream. See xdr_logs.zip.
> 
> I also attached the original xdr_stdio.c and a diff with everything I added.
> 
> When I now run our test v.out.ogr line:
> 
> GRASS 6.3.cvs (qgis-test):C:\GRASSSRC\grass6\bin.i686-pc-mingw32
> >v.out.ogr points type=point dsn=c:\test
> 
> I get the message:
> 
> Exporting 2898 points/lines...
> 
> And then nothing else. The percentage counter never appears.
> 
> Please tell me if these logs are in any way helpful and, if not, what I
> could do to improve them.

The first things which spring to mind are:

1. There needs to be a single log file for each process, i.e. one for
the client, one for the driver. It should be possible to display the
files side-by-side and match each "write" from the client with the
corresponding "read" from the driver and vice-versa.

2. The debug code needs to call fflush() after each record. Otherwise,
data will be missing from the end of the file if the process
terminates abnormally (see getlong1.txt). Moreover, the part which is
missing is likely to be the most useful.

3. The actual data which is read or written should be included in the
log entry.

-- 
Glynn Clements <glynn at gclements.plus.com>




More information about the grass-dev mailing list