Commit 4c5f9b79 authored by Vincent Castellano's avatar Vincent Castellano

Add missing null check

parent 5285cf2b
...@@ -808,7 +808,7 @@ void py_do_all (void) { ...@@ -808,7 +808,7 @@ void py_do_all (void) {
break; break;
case pq_msg: case pq_msg:
if(PyArg_ParseTuple(args, "O!s#|OO", &tgl_PeerType, &peer, &str, &len, &cb_extra, &pyObj1)) { if(PyArg_ParseTuple(args, "O!s#|OO", &tgl_PeerType, &peer, &str, &len, &cb_extra, &pyObj1)) {
if(PyArg_ParseTuple(pyObj1, "ii", &preview, &reply_id)) { if(pyObj1 && PyArg_ParseTuple(pyObj1, "ii", &preview, &reply_id)) {
if(preview != -1) { if(preview != -1) {
if(preview) if(preview)
flags |= TGL_SEND_MSG_FLAG_ENABLE_PREVIEW; flags |= TGL_SEND_MSG_FLAG_ENABLE_PREVIEW;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment