aboutsummaryrefslogtreecommitdiff
path: root/libstdc++-v3
diff options
context:
space:
mode:
authorJeffrey D. Oldham <oldham@gcc.gnu.org>2003-11-05 04:37:03 +0000
committerJeffrey D. Oldham <oldham@gcc.gnu.org>2003-11-05 04:37:03 +0000
commitd30b600a6e22cb030fa61cfcfb3970d6289c08f3 (patch)
treef594dd7812e9b82194b071677b0cb8f5408a4ecc /libstdc++-v3
parent177bda879bc5a97d960df9659df5bc1788aa8561 (diff)
downloadgcc-d30b600a6e22cb030fa61cfcfb3970d6289c08f3.zip
gcc-d30b600a6e22cb030fa61cfcfb3970d6289c08f3.tar.gz
gcc-d30b600a6e22cb030fa61cfcfb3970d6289c08f3.tar.bz2
vec.cc (__cxa_vec_delete2): If given a NULL pointer, immediately return.
2003-11-04 Jeffrey D. Oldham <oldham@codesourcery.com> * libsupc++/vec.cc (__cxa_vec_delete2): If given a NULL pointer, immediately return. This reflects a C++ ABI change 2003 Nov 03. (__cxa_vec_delete3): Likewise. From-SVN: r73263
Diffstat (limited to 'libstdc++-v3')
-rw-r--r--libstdc++-v3/ChangeLog7
-rw-r--r--libstdc++-v3/libsupc++/vec.cc17
2 files changed, 21 insertions, 3 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog
index 9124c8d..9066d60 100644
--- a/libstdc++-v3/ChangeLog
+++ b/libstdc++-v3/ChangeLog
@@ -1,3 +1,9 @@
+2003-11-04 Jeffrey D. Oldham <oldham@codesourcery.com>
+
+ * libsupc++/vec.cc (__cxa_vec_delete2): If given a NULL pointer,
+ immediately return. This reflects a C++ ABI change 2003 Nov 03.
+ (__cxa_vec_delete3): Likewise.
+
2003-11-03 Petur Runolfsson <peturr02@ru.is>
PR libstdc++/12790
@@ -103,6 +109,7 @@
* include/bits/istream.tcc: Same.
* include/bits/ostream.tcc: Same.
+>>>>>>> 1.2063
2003-10-30 Paolo Carlini <pcarlini@suse.de>
* include/bits/locale_facets.tcc (time_get::_M_extract_via_format):
diff --git a/libstdc++-v3/libsupc++/vec.cc b/libstdc++-v3/libsupc++/vec.cc
index e2c8f09..2725593 100644
--- a/libstdc++-v3/libsupc++/vec.cc
+++ b/libstdc++-v3/libsupc++/vec.cc
@@ -282,7 +282,12 @@ namespace __cxxabiv1
void (*destructor) (void *),
void (*dealloc) (void *))
{
- char *base = static_cast<char *>(array_address);
+ char *base;
+
+ if (!array_address)
+ return;
+
+ base = static_cast<char *>(array_address);
if (padding_size)
{
@@ -312,8 +317,14 @@ namespace __cxxabiv1
void (*destructor) (void *),
void (*dealloc) (void *, std::size_t))
{
- char *base = static_cast <char *> (array_address);
- std::size_t size = 0;
+ char *base;
+ std::size_t size;
+
+ if (!array_address)
+ return;
+
+ base = static_cast <char *> (array_address);
+ size = 0;
if (padding_size)
{