PATCH: Fix assorted bounds violations

Greg McGary greg@mcgary.org
Mon Sep 4 01:16:00 GMT 2000


Greg McGary <greg@mcgary.org> writes:

> Index: include/bounded-ptr.h
> ...
> +# define RELOCATE_POINTER(PTR, DISP) (PTR)
> +# define RELOCATE_POINTER_INCR_HIGH(PTR, DISP, INCR) (PTR)
> +# define RELOCATE_POINTER_SET_HIGH(PTR, DISP, N) (PTR)

These were wrong, and are now fixed.  The broken defn's didn't
relocate, just returned the original PTR.  These are good:

# define RELOCATE_POINTER(PTR, DISP) ((PTR) += (DISP))
# define RELOCATE_POINTER_INCR_HIGH(PTR, DISP, INCR) ((PTR) += (DISP))
# define RELOCATE_POINTER_SET_HIGH(PTR, DISP, LENGTH) ((PTR) += (DISP))

> Index: gcc/ginclude/bounded-ptr.h

Same change for this file.

Greg


More information about the Gcc-patches mailing list