[GRASS-dev] [GRASS GIS] #968: v.net.salesman problem with memory allocation

GRASS GIS trac at osgeo.org
Sun Feb 28 09:01:13 EST 2010


#968: v.net.salesman problem with memory allocation
-------------------------+--------------------------------------------------
 Reporter:  marisn       |       Owner:  grass-dev at lists.osgeo.org
     Type:  defect       |      Status:  new                      
 Priority:  major        |   Milestone:  6.4.0                    
Component:  Vector       |     Version:  unspecified              
 Keywords:  v.net        |    Platform:  Linux                    
      Cpu:  Unspecified  |  
-------------------------+--------------------------------------------------
 v.net.salesman does something wrong during memory allocation. Normaly it
 results into assertion in malloc call.
 {{{
 v.net.salesman: malloc.c:4633: _int_malloc: Assertion
 `victim->fd_nextsize->bk_nextsize == victim' failed.
 }}}
 Valgrind reports invalid write (will attach full valgrind output as an
 attachment).
 {{{
 Number of cities: [6]
 ==6589== Invalid write of size 8
 ==6589==    at 0x401FAF: main (main.c:209)
 ==6589==  Address 0xd18cbc8 is 0 bytes after a block of size 40 alloc'd
 ==6589==    at 0x4C25EE5: malloc (in /usr/lib64/valgrind/
 vgpreload_memcheck-amd64-linux.so)
 ==6589==    by 0x529118F: G__malloc (alloc.c:41)
 ==6589==    by 0x401F64: main (main.c:207)
 }}}

 GRASS 6.4 r41215 on ~AMD64 Gentoo.
 6.5 is also affected.

 I'm unable to reproduce with Spearfish. Will attach sample dataset.

-- 
Ticket URL: <http://trac.osgeo.org/grass/ticket/968>
GRASS GIS <http://grass.osgeo.org>


More information about the grass-dev mailing list