Base/App: fix warnings from code analysers:
* convert old-style-casts to explicit C++ casts where possible * make some implicit conversions explicit
This commit is contained in:
@@ -166,7 +166,7 @@ std::string Base::Tools::escapedUnicodeToUtf8(const std::string& s)
|
||||
Base::PyGILStateLocker lock;
|
||||
std::string string;
|
||||
|
||||
PyObject* unicode = PyUnicode_DecodeUnicodeEscape(s.c_str(), s.size(), "strict");
|
||||
PyObject* unicode = PyUnicode_DecodeUnicodeEscape(s.c_str(), static_cast<Py_ssize_t>(s.size()), "strict");
|
||||
if (!unicode)
|
||||
return string;
|
||||
if (PyUnicode_Check(unicode)) {
|
||||
|
||||
Reference in New Issue
Block a user