[vlc-commits] commit: skins2(Linux): check if _NET_WM_PID is supported (Erwan Tulou )

git at videolan.org git at videolan.org
Mon Jun 28 11:09:44 CEST 2010


vlc/vlc-1.1 | branch: master | Erwan Tulou <erwan10 at videolan.org> | Mon Jun 28 10:13:03 2010 +0200| [766d4696e57c30feebf990e1d56c7196e76c1e26] | committer: Erwan Tulou 

skins2(Linux): check if _NET_WM_PID is supported

This kills X11 warnings for Ubuntu/Gnome.
(cherry picked from commit 2eb55c6d8e2c2932a9703070fddabca6a18633e0)

> http://git.videolan.org/gitweb.cgi/vlc/vlc-1.1.git/?a=commit;h=766d4696e57c30feebf990e1d56c7196e76c1e26
---

 modules/gui/skins2/x11/x11_window.cpp |    9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/modules/gui/skins2/x11/x11_window.cpp b/modules/gui/skins2/x11/x11_window.cpp
index 4b26433..28d3e0b 100644
--- a/modules/gui/skins2/x11/x11_window.cpp
+++ b/modules/gui/skins2/x11/x11_window.cpp
@@ -184,9 +184,12 @@ X11Window::X11Window( intf_thread_t *pIntf, GenericWindow &rWindow,
     delete[] hostname;
 
     // initialize EWMH pid
-    pid_t pid = getpid();
-    XChangeProperty( XDISPLAY, m_wnd, NET_WM_PID, XA_CARDINAL, 32,
-                     PropModeReplace, (unsigned char *)&pid, 1 );
+    if( NET_WM_PID != None )
+    {
+        pid_t pid = getpid();
+        XChangeProperty( XDISPLAY, m_wnd, NET_WM_PID, XA_CARDINAL, 32,
+                         PropModeReplace, (unsigned char *)&pid, 1 );
+    }
 
 }
 



More information about the vlc-commits mailing list