[Bug libstdc++/21172] potential integer overflow error in STL heap functions

paolo at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Tue Feb 13 00:25:00 GMT 2007



------- Comment #7 from paolo at gcc dot gnu dot org  2007-02-13 00:25 -------
Subject: Bug 21172

Author: paolo
Date: Tue Feb 13 00:25:30 2007
New Revision: 121875

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=121875
Log:
2007-02-12  Paolo Carlini  <pcarlini@suse.de>

        PR libstdc++/21172
        * include/bits/stl_heap.h (__adjust_heap(_RandomAccessIterator,
        _Distance, _Distance, _Tp), __adjust_heap(_RandomAccessIterator,
        _Distance, _Distance, _Tp, _Compare)): Avoid potential integer
        overflow.

        * include/bits/stl_heap.h (__is_heap(_RandomAccessIterator,
        _RandomAccessIterator), __is_heap(_RandomAccessIterator,
        _RandomAccessIterator, _StrictWeakOrdering): Mark inline.
        (make_heap(_RandomAccessIterator, _RandomAccessIterator,
        _Compare)): Do not mark inline.

        * include/bits/stl_heap.h (push_heap(_RandomAccessIterator,
        _RandomAccessIterator), sort_heap(_RandomAccessIterator,
        _RandomAccessIterator)): Uncomment __glibcxx_requires_heap.

Modified:
    trunk/libstdc++-v3/ChangeLog
    trunk/libstdc++-v3/include/bits/stl_heap.h


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21172



More information about the Gcc-bugs mailing list