This patch fixes two off-by-one errors accessing the
signal names list
in sig_msgs[].
The problem fixed is that without this patch sig_msgs
was declared as
sig_msgs[20], thus sig_msgs[0]..sig_msgs[19] was
allocated. But the
initialization code did assign values up to
sig_msgs[20]. Later on, while
printing the signal name, the last "valid" index was
i==ARRSIZE(sig_msgs)
(==20) which also did access the invalid entry
sig_msgs[20].
Logged In: YES
user_id=1195173
Applying to cvs trunk.
**
2005-10-22 Perry Rapp
* ChangeLog src/stdlib/signals.c
Fix signal name array size.
sf Patch#1334872: Fix off-by-one access to signal names list
By Andreas Kirschbaum
**
Checking in ChangeLog;
/cvsroot/lifelines/lifelines/ChangeLog,v <-- ChangeLog
new revision: 1.1704; previous revision: 1.1703
done
Checking in src/stdlib/signals.c;
/cvsroot/lifelines/lifelines/src/stdlib/signals.c,v <--
signals.c
new revision: 1.42; previous revision: 1.41
done
Success, CVS operation completed