[GRASS5] [bug #2767] (grass) r.stats bug (due to recent G_store() fix?)

Paul Kelly via RT grass-bugs at intevation.de
Tue Dec 7 16:21:08 EST 2004


I'm not sure this line:
if (title == NULL) title="";
looks right.
Perhaps try changing to
if (title == NULL) *title="";
Makes more logical sense but still might not work.

If it doesn't something like this might:
int 
G_set_raster_cats_title (char *intitle, struct Categories *pcats)
{
    char *title;
    if (intitle == NULL)
      *title="";
    else
      title=intitle;
    pcats->title = G_store (title);
    G_newlines_to_spaces (pcats->title);
    G_strip (pcats->title);
      return 0;
}




-------------------------------------------- Managed by Request Tracker




More information about the grass-dev mailing list