Index: lldb/trunk/scripts/Python/python-swigsafecast.swig =================================================================== --- lldb/trunk/scripts/Python/python-swigsafecast.swig +++ lldb/trunk/scripts/Python/python-swigsafecast.swig @@ -27,15 +27,6 @@ template <> PyObject* -SBTypeToSWIGWrapper (const char* c_str) -{ - if (c_str) - return PyString_FromString(c_str); - return NULL; -} - -template <> -PyObject* SBTypeToSWIGWrapper (unsigned int* c_int) { if (!c_int) Index: lldb/trunk/scripts/Python/python-wrapper.swig =================================================================== --- lldb/trunk/scripts/Python/python-wrapper.swig +++ lldb/trunk/scripts/Python/python-wrapper.swig @@ -826,7 +826,9 @@ lldb::SBFrame frame_sb(frame_sp); PyObject *arg = SBTypeToSWIGWrapper(frame_sb); - PyObject* result = PyObject_CallMethodObjArgs(implementor, PyString_FromString(callee_name), arg, NULL); + PythonString str(callee_name); + PyObject* result = PyObject_CallMethodObjArgs(implementor, str.get(), arg, + NULL); return result; }