[GRASS-dev] erratic behavior of v.in.ascii with WinGRASS

Glynn Clements glynn at gclements.plus.com
Fri Feb 8 17:05:56 EST 2008


Moritz Lennert wrote:

> > Will have to debug some more...
> 
> Have gotten a bit further. It seems that the problem is in 
> lib/db/dbmi_base/xdr.c with the readn function, when executing the 
> function read at line 40.
> 
> Glynn, any hints for futher debugging ?

Ick. It might be a protocol issue. Or it might be a bug elsewhere
which only shows up when the non-failing side gets given bogus data by
the failing side.

The DBMI protocol is quite fragile. If you send anything other than
what the receiver is expecting, the receiver is likely to die.

As for protocol issues: if it's specific to Windows, inadvertant CRLF
translation (i.e. lack of _fmode=_O_BINARY) is a candidate. Another
issue is that the driver communicates via its stdin/stdout. If some
library function decides to write some text to stdout, the client is
going to treat it as DBMI protocol with unpredictable consequences.

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


More information about the grass-dev mailing list