summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRenato Araujo Oliveira Filho <renato.filho@openbossa.org>2011-01-07 18:58:15 -0300
committerRenato Araujo Oliveira Filho <renato.filho@openbossa.org>2011-01-07 19:15:41 -0300
commit0f6a504dfb06b69b918fbc94db361cfbce9b62a3 (patch)
tree48f2872f7dc29716bb71edbbea86ffcafbe8ae0c
parentefdedcdd016c491b31e8432ec47b16d2265fdbfd (diff)
downloadpyside-0f6a504dfb06b69b918fbc94db361cfbce9b62a3.tar.gz
pyside-0f6a504dfb06b69b918fbc94db361cfbce9b62a3.tar.xz
pyside-0f6a504dfb06b69b918fbc94db361cfbce9b62a3.zip
Fix Qvariant to Cpp conversion.
Fixes bug #589 Reviewer: Hugo Parente Lima <hugo.lima@openbossa.org> Marcelo Lira <marcelo.lira@openbossa.org>
-rw-r--r--PySide/QtCore/qvariant_conversions.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/PySide/QtCore/qvariant_conversions.h b/PySide/QtCore/qvariant_conversions.h
index 0b89534..283cf4f 100644
--- a/PySide/QtCore/qvariant_conversions.h
+++ b/PySide/QtCore/qvariant_conversions.h
@@ -19,6 +19,8 @@ struct Converter<QVariant>
if (PyObject_TypeCheck(type, &SbkObjectType_Type)) {
SbkObjectType* sbkType = reinterpret_cast<SbkObjectType*>(type);
const char* typeName = Shiboken::ObjectType::getOriginalName(sbkType);
+ if (!typeName)
+ return 0;
bool valueType = '*' != typeName[qstrlen(typeName) - 1];
// Do not convert user type of value