[GRASS5] Non-portable code in 5.1 portability test

Radim Blazek blazek at itc.it
Mon Mar 3 08:13:01 EST 2003


On Saturday 01 March 2003 07:26 pm, cheg01 at attbi.com wrote:
> The file /lib/vector/diglib/test.c fails on Solaris. Under Solaris, you
> cannot perform a write immediately after a on the same file without
> performing fflush(fp) in between or closing and reopening the file.

Thanks for this information. I fixed that in test.c but the problem 
remains in the library. 
If the vector is opened for update Vect_open_update() and new line is written 
Vect_write_line()(calls fflush()) and read by Vect_read_next_line() or 
Vect_read_line() (do not call fflush()) next call to Vect_write_line() should 
fail, is it right? Can you give any recommendation where to add fflush().
I think that before fwrite() in Vect_write_line().

I would highly appreciate if you could test if vector binaries
are realy portable between more platforms (write on one and read on 
another). I have never tested any other than intel. Could you send me
grass51/dist.$(ARCH)/include/portable.h? Just for my collection.


Radim




More information about the grass-dev mailing list