[GRASS5] ps.map problem resolved

Glynn Clements glynn.clements at virgin.net
Fri Oct 25 06:32:05 EDT 2002


Michael Ash wrote:

> (I remain puzzled why the "size 1" line did NOT cause a
> problem, only the "color red" line.)

The code which processes "size" calls C's sscanf() operator, which
stops when it reaches an invalid character. OTOH, the code which
processes "color" strips any spaces and tabs, then uses strcmp() to
compare the string against each element of a table until it finds a
match.

We should probably change functions such as G_strip(), G_getl() etc to
strip any trailing CR characters.

-- 
Glynn Clements <glynn.clements at virgin.net>




More information about the grass-dev mailing list