This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Ada] Protect against uninitialize field in atree.adb


[Ada] Protect against uninitialize field in atree.adb

Tested on i686-linux, committed on mainline.

The spec of Atree requires that for all Elist functions, a value of
zero should be treated as No_Elist. In pratice this had been done
only for certain functions where blowups had been encountered.
This left a nasty situation where the Atree body did not meet the
spec, and in addition, had unaurthorized covert knowledge of which
Elist routines needed this protection. This patch cleans things up
and makes sure that all Elist routines meet the spec. It is not
clear if this fixes any existing bugs, but it certainly is a
correct fix, and may fix existing bugs, as well as latent bugs
in the future, since a user of Atree is perfectly well entitled
to assume that the body corresponds to the spec!

2005-06-14  Robert Dewar  <dewar@adacore.com>

	* atree.adb: (Elist*): Protect against uninitialized field

Attachment: difs.15
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]