[GRASS-dev] [GRASS GIS] #3062: Segmentation fault with r.buffer

GRASS GIS trac at osgeo.org
Thu Jun 16 21:07:47 PDT 2016


#3062: Segmentation fault with r.buffer
-----------------------+-------------------------
  Reporter:  escheper  |      Owner:  grass-dev@…
      Type:  defect    |     Status:  new
  Priority:  blocker   |  Milestone:  7.0.5
 Component:  Raster    |    Version:  7.0.4
Resolution:            |   Keywords:  r.buffer
       CPU:  Other     |   Platform:  Linux
-----------------------+-------------------------

Comment (by annakrat):

 I would say it is related to the fact that `to_ptr` is unsigned char, so
 it can overflow fast, although I don't understand the algorithm there.
 Note the comment in the code:
 {{{
 /* if MAPTYPE is changed to unsigned short, MAX_DIST can be set to 2^16-2
  * (if short is 2 bytes)
  */
 }}}
 So I would try to change it to unsigned short. Unfortunately I can't
 easily test the testcase, I have little memory right now.

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



More information about the grass-dev mailing list