projects
/
wxWidgets.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1b10056
)
Return from DoDrawSpline without doing anything (like segfaulting
author
Robin Dunn
<robin@alldunn.com>
Wed, 27 Oct 2004 01:00:09 +0000
(
01:00
+0000)
committer
Robin Dunn
<robin@alldunn.com>
Wed, 27 Oct 2004 01:00:09 +0000
(
01:00
+0000)
<wink!>) if the list is empty.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@30106
c3d73ce0
-8a6f-49c7-b76d-
6d57e0e08775
src/common/dcbase.cpp
patch
|
blob
|
blame
|
history
diff --git
a/src/common/dcbase.cpp
b/src/common/dcbase.cpp
index 10c928e505c681fa176609d038e94e9560a5bfd2..fadb078d01ba56eaa8703cbc3436937a31aeb167 100644
(file)
--- a/
src/common/dcbase.cpp
+++ b/
src/common/dcbase.cpp
@@
-316,6
+316,10
@@
void wxDCBase::DoDrawSpline( wxList *points )
double x1, y1, x2, y2;
wxList::compatibility_iterator node = points->GetFirst();
+ if (node == NULL)
+ // empty list
+ return;
+
p = (wxPoint *)node->GetData();
x1 = p->x;