[GRASS-dev] Re: testing native winGRASS

Moritz Lennert mlennert at club.worldonline.be
Wed Mar 14 10:29:16 EDT 2007


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 13/03/07 23:34, Paul Kelly wrote:
> Hello Moritz
> 
> On Tue, 13 Mar 2007, Moritz Lennert wrote:
> 
>> 1) Create location with projection values: location created but mapset
>> (other than PERMANENT) invalid
> 
> Could you try the patch below for lib/gis/getl.c and see if GRASS can
> then handle the newly created location? I think the problem is the
> created location contains Windows line endings in some of the files and
> other GRASS functions can't handle them. G_getl2() handles Windows line
> endings whereas G_getl() does not. I have a hunch this may apply in many
> places.

I will try this tonight, but just to make clear what is going wrong:
creating the location works and there is a valid PERMANENT mapset
created whatever I do, but if (in the console window where you enter the
name of the new location) I give a mapset name other than PERMANENT,
this mapset is then created (together with PERMANENT), but when I try to
enter it, I get an "invalid mapset" error, which is understandable since
the mapset directory is empty except for a dbf directory (IIRC).

Moritz


> 
> Index: getl.c
> ===================================================================
> RCS file: /home/grass/grassrepository/grass6/lib/gis/getl.c,v
> retrieving revision 2.6
> diff -u -r2.6 getl.c
> --- getl.c      12 Nov 2006 04:05:02 -0000      2.6
> +++ getl.c      13 Mar 2007 22:31:02 -0000
> @@ -16,6 +16,8 @@
> 
>  int G_getl ( char *buf, int n, FILE *fd)
>  {
> +    return G_getl2 ( buf, n, fd );
> +   /*
>      if (!fgets (buf, n, fd))
>         return 0;
> 
> @@ -24,6 +26,7 @@
>      *buf = 0;
> 
>      return 1;
> +    */
>  }
> 

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFF+Aa8MiPFf/8qzFYRAl18AKCXOhyMDJMOAOQMdbI2D8T0xI98lQCfbhuD
3mPFzCfqifeyRuJob7BEUWs=
=uGoV
-----END PGP SIGNATURE-----




More information about the grass-dev mailing list