projects
/
wxWidgets.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
28cafc4
)
fixed a serious bug in Shrink()
author
Vadim Zeitlin
<vadim@wxwidgets.org>
Mon, 10 Mar 2003 18:11:15 +0000
(18:11 +0000)
committer
Vadim Zeitlin
<vadim@wxwidgets.org>
Mon, 10 Mar 2003 18:11:15 +0000
(18:11 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@19535
c3d73ce0
-8a6f-49c7-b76d-
6d57e0e08775
src/common/dynarray.cpp
patch
|
blob
|
blame
|
history
diff --git
a/src/common/dynarray.cpp
b/src/common/dynarray.cpp
index 72284fcb73ca57ffe1520af6ee887457d16af0a5..c6890ce3a09c4cd44bf7889b6d84e1081b0067b3 100644
(file)
--- a/
src/common/dynarray.cpp
+++ b/
src/common/dynarray.cpp
@@
-221,7
+221,11
@@
void name::Shrink() \
memcpy(pNew, m_pItems, m_nCount*sizeof(T)); \
delete [] m_pItems; \
m_pItems = pNew; \
+ \
+ /* update the size of the new block */ \
+ m_nSize = m_nCount; \
} \
+ /* else: don't do anything, better keep old memory block! */ \
} \
} \
\