[GRASS-dev] [GRASS GIS] #2872: "r.info -e" output not compliant with eval

GRASS GIS trac at osgeo.org
Thu Jan 21 06:15:54 PST 2016


#2872: "r.info -e" output not compliant with eval
----------------------------+---------------------------
  Reporter:  andbal         |      Owner:  grass-dev@…
      Type:  defect         |     Status:  new
  Priority:  normal         |  Milestone:  7.0.3
 Component:  Shell Scripts  |    Version:  svn-trunk
Resolution:                 |   Keywords:  shell, r.info
       CPU:  x86-64         |   Platform:  Linux
----------------------------+---------------------------
Changes (by neteler):

 * milestone:   => 7.0.3


Comment:

 Replying to [comment:1 andbal]:
 > I add the output of {{{r.info -e}}} executed outside {{{eval}}}
 > {{{
 > ...
 > comments="i.eb.soilheatflux albedo="albedo.dos4" ndvi="ndvi.dos4"
 temperature=\"toa_temp.6" netradiation="rad.M1"
 localutctime="overpass_utc" outpu\t="soilheatflux.dos4""
 > }}}

 The issue is that the inner quotes " need to be escaped when fprintf'ing
 the comment:

 https://trac.osgeo.org/grass/browser/grass/trunk/raster/r.info/main.c#L392

 I suppose that there is already a function for that?

--
Ticket URL: <https://trac.osgeo.org/grass/ticket/2872#comment:2>
GRASS GIS <https://grass.osgeo.org>



More information about the grass-dev mailing list