[GRASS-dev] [GRASS GIS] #3062: Segmentation fault with r.buffer
GRASS GIS
trac at osgeo.org
Wed Jun 15 08:48:42 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 neteler):
{{{
CMD='r.buffer input=r120749038 output=rasbuf distances=10.0
units=kilometers --o'
valgrind --tool=memcheck --leak-check=yes --show-reachable=yes $CMD --o
==11148== Memcheck, a memory error detector
==11148==
==11148== 933,120,000 bytes in 1 blocks are still reachable in loss record
73 of 73
==11148== at 0x4C2AB80: malloc (in /usr/lib/valgrind
/vgpreload_memcheck-amd64-linux.so)
==11148== by 0x5076A4A: G__malloc (alloc.c:39)
==11148== by 0x40333B: read_input_map (read_map.c:39)
==11148== by 0x402814: main (main.c:141)
...
}}}
There is no G_free(map) it seems:
{{{
raster/r.buffer $ grep 'alloc\|free' *.c | grep -v GNU
parse_dist.c: distances = (struct Distance *)G_calloc(count,
sizeof(struct Distance));
read_map.c: map = (MAPTYPE *) G_malloc((size_t) window.rows *
window.cols * sizeof(MAPTYPE));
read_map.c: cell = Rast_allocate_c_buf();
read_map.c: G_free(cell);
support.c: Rast_free_cats(&pcats);
write_map.c: cell = Rast_allocate_c_buf();
write_map.c: G_free(cell);
}}}
--
Ticket URL: <https://trac.osgeo.org/grass/ticket/3062#comment:6>
GRASS GIS <https://grass.osgeo.org>
More information about the grass-dev
mailing list