http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60547
Bug ID: 60547
Summary: libcilkrts/runtime/record-replay.cpp: 2 * possible
problems in calls to scanf ?
Product: gcc
Version: 4.9.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: other
Assignee: unassigned at gcc dot gnu.org
Reporter: dcb314 at hotmail dot com
Static analyser cppcheck says
1.
[libcilkrts/runtime/record-replay.cpp:561]: (warning) scanf without field width
limits can crash with huge input data.
Source code is
fret = fscanf(f, "%s %s %d %d\n", ped_type, ped_str, &i1, &i2);
but
char ped_type[PED_TYPE_SIZE];
It might be worthwhile to limit the %s to PED_TYPE_SIZE
2.
[libcilkrts/runtime/record-replay.cpp:569]: (warning) scanf without field width
limits can crash with huge input data.
Duplicate.