mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-05-04 17:10:47 +00:00
If a python error has occurred, don't try to do any work, just bail
This commit is contained in:
@@ -734,6 +734,9 @@ PyObject *PythonContext::outstream_write(PyObject *self, PyObject *args)
|
||||
if(!PyArg_ParseTuple(args, "z:write", &text))
|
||||
return NULL;
|
||||
|
||||
if(PyErr_Occurred())
|
||||
return NULL;
|
||||
|
||||
OutputRedirector *redirector = (OutputRedirector *)self;
|
||||
|
||||
if(redirector)
|
||||
@@ -774,6 +777,9 @@ PyObject *PythonContext::outstream_write(PyObject *self, PyObject *args)
|
||||
|
||||
PyObject *PythonContext::outstream_flush(PyObject *self, PyObject *args)
|
||||
{
|
||||
if(PyErr_Occurred())
|
||||
return NULL;
|
||||
|
||||
Py_RETURN_NONE;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user