[GRASS5] ps.map problem resolved

Radim Blazek blazek at itc.it
Fri Oct 25 03:19:14 EDT 2002


On Thursday 24 October 2002 08:04 pm, Michael Ash wrote:
> Radim's suggestion indeed resolved the problem.  From the
> cygwin command line, I ran
>
> tr -d '\015' < oldmapinstructions > newmapinstructions
>
> and newmapinstructions ran with a problem as the input to ps.map
>
> Thank you very much.
>
> (I remain puzzled why the "size 1" line did NOT cause a
> problem, only the "color red" line.)

Size as integer is converted to number by atoi() which handles <CR>,
color is string, compared to existing colors by strcmp().
We should use G_chop() before comparison which should remove both 
'\n' and '\r'.

Radim




More information about the grass-dev mailing list