From d5ae18cc545b8390aa40bfe536f0b2cdf39edcbf Mon Sep 17 00:00:00 2001 From: rbdpngn Date: Sat, 11 Oct 2003 22:15:44 +0000 Subject: [PATCH] Added checks for the root window to the string property functions. SVN revision: 7532 --- legacy/ecore/src/lib/ecore_x/ecore_x_window_prop.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/legacy/ecore/src/lib/ecore_x/ecore_x_window_prop.c b/legacy/ecore/src/lib/ecore_x/ecore_x_window_prop.c index 71f1b25e8f..b3c94651a5 100644 --- a/legacy/ecore/src/lib/ecore_x/ecore_x_window_prop.c +++ b/legacy/ecore/src/lib/ecore_x/ecore_x_window_prop.c @@ -98,6 +98,7 @@ ecore_x_window_prop_string_set(Ecore_X_Window win, Ecore_X_Atom type, char *str) { XTextProperty xtp; + if (win == 0) win = DefaultRootWindow(_ecore_x_disp); xtp.value = str; xtp.format = 8; xtp.encoding = XA_STRING; @@ -119,6 +120,7 @@ ecore_x_window_prop_string_get(Ecore_X_Window win, Ecore_X_Atom type) XTextProperty xtp; char *str = NULL; + if (win == 0) win = DefaultRootWindow(_ecore_x_disp); if (XGetTextProperty(_ecore_x_disp, win, &xtp, type)) { int items;