Opened 10 years ago

Closed 6 years ago

#1705 closed defect (fixed) segfaults on empty input

Reported by: neteler Owned by: grass-dev@…
Priority: minor Milestone: 7.0.5
Component: Imagery Version: svn-trunk
Keywords: Cc:
CPU: x86-64 Platform: Linux


When running with *empty* input (as it can happen from an unsuccessful g.mlist call piped into it), it segfaults: group=tmean_avg input=""
Segmentation fault (core dumped)

The real call was: group=tmean_avg input=`g.mlist rast pat="tmean.1981_2010.??.avg sep=,"`
Segmentation fault (core dumped)

but g.mlist did not return anything due to a typo in the map name pattern.

GDB (line broken for readability):

(gdb) run group=tmean_0_25deg_1981_2010_avg \
  input=`g.mlist rast pat="tmean_0_25deg.1981_2010.??.avg sep=,"`

Program received signal SIGSEGV, Segmentation fault.
0x00007ffff7bb2ee6 in G_name_is_fully_qualified \
(fullname=0x0, name=0x7fffffffd410 "", mapset=0x7fffffffd310 "") 
at nme_in_mps.c:45

Change History (4)

comment:1 by martinl, 7 years ago


comment:2 by martinl, 6 years ago

In 69227: segfaults on empty input (see #1705)

comment:3 by martinl, 6 years ago

In 69228: segfaults on empty input (see #1705) (merge r69227 from trunk)

comment:4 by martinl, 6 years ago

Resolution: fixed
Status: newclosed

In 69229: segfaults on empty input (fix #1705) (merge r69227 from trunk)

Note: See TracTickets for help on using tickets.