From 1240a709b8e3732c2054a49994ca01034120e895 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Fri, 6 Sep 2013 04:40:49 +0000 Subject: [PATCH] minor refactor git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@74766 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/dc_ex.cpp | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/dc_ex.cpp b/src/dc_ex.cpp index b7b45b46..4bccf48e 100644 --- a/src/dc_ex.cpp +++ b/src/dc_ex.cpp @@ -317,19 +317,16 @@ PyObject* wxPyDrawTextList(wxDC& dc, PyObject* textList, PyObject* pyPoints, PyO Py_DECREF(obj); goto err0; } + if (!isFastText) + Py_DECREF(obj); + if (PyErr_Occurred()) { retval = NULL; - if (!isFastSeq) - Py_DECREF(obj); goto exit; } - // Now draw the text dc.DrawText(string, x1, y1); - - if (!isFastText) - Py_DECREF(obj); } Py_INCREF(Py_None);