diff options
Diffstat (limited to 'src/plugins/platforms/xcb/qxcbscreen.cpp')
-rw-r--r-- | src/plugins/platforms/xcb/qxcbscreen.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/platforms/xcb/qxcbscreen.cpp b/src/plugins/platforms/xcb/qxcbscreen.cpp index 0bc38869ac..79f37bb028 100644 --- a/src/plugins/platforms/xcb/qxcbscreen.cpp +++ b/src/plugins/platforms/xcb/qxcbscreen.cpp @@ -865,7 +865,7 @@ QByteArray QXcbScreen::getOutputProperty(xcb_atom_t atom) const xcb_randr_get_output_property(xcb_connection(), m_output, atom, XCB_ATOM_ANY, 0, 100, false, false); auto reply = xcb_randr_get_output_property_reply(xcb_connection(), cookie, nullptr); - if (reply->type == XCB_ATOM_INTEGER && reply->format == 8) { + if (reply && reply->type == XCB_ATOM_INTEGER && reply->format == 8) { quint8 *data = new quint8[reply->num_items]; memcpy(data, xcb_randr_get_output_property_data(reply), reply->num_items); result = QByteArray(reinterpret_cast<const char *>(data), reply->num_items); |