xserver: check whether pointer exists when exiting
At initialization, if it fails in binding the socket or creating the lock file then the pointer will be already freed and will result a segfault when quiting the compositor. Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
This commit is contained in:
committed by
Kristian Høgsberg
parent
7e69000556
commit
37f27d59cd
@@ -808,6 +808,9 @@ wlsc_xserver_destroy(struct wlsc_compositor *compositor)
|
|||||||
{
|
{
|
||||||
struct wlsc_xserver *wxs = compositor->wxs;
|
struct wlsc_xserver *wxs = compositor->wxs;
|
||||||
|
|
||||||
|
if (!wxs)
|
||||||
|
return;
|
||||||
|
|
||||||
if (wxs->loop)
|
if (wxs->loop)
|
||||||
wlsc_xserver_shutdown(wxs);
|
wlsc_xserver_shutdown(wxs);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user