Enlightenment CVS committal
Author : kwo
Project : e16
Module : e
Dir : e16/e/src
Modified Files:
actions.c atoms.c comms.c icccm.c ipc.c mwm.c setup.c x.c
Log Message:
Fix gcc 3.3 compiler warnings.
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/actions.c,v
retrieving revision 1.116
retrieving revision 1.117
diff -u -3 -r1.116 -r1.117
--- actions.c 7 Dec 2003 09:18:55 -0000 1.116
+++ actions.c 11 Dec 2003 21:13:50 -0000 1.117
@@ -2875,7 +2875,7 @@
if (!params)
EDBUG_RETURN(0);
- sscanf((char *)params, "%i", (int *)&win);
+ sscanf((char *)params, "%li", &win);
ewin = (EWin *) FindItem(NULL, win, LIST_FINDBY_ID, LIST_TYPE_EWIN);
if (ewin)
{
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/atoms.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -3 -r1.13 -r1.14
--- atoms.c 5 Nov 2003 17:24:42 -0000 1.13
+++ atoms.c 11 Dec 2003 21:13:50 -0000 1.14
@@ -94,7 +94,7 @@
getSimpleHint(Window win, Atom atom)
{
- long *data = 0;
+ unsigned char *data = NULL;
Atom type_ret;
int fmt_ret;
unsigned long nitems_ret;
@@ -107,7 +107,7 @@
if (XGetWindowProperty
(disp, win, atom, 0, 1, False, atom, &type_ret, &fmt_ret, &nitems_ret,
- &bytes_after_ret, (unsigned char **)&data) != Success || !data)
+ &bytes_after_ret, &data) != Success || !data)
{
if (data)
XFree(data);
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/comms.c,v
retrieving revision 1.36
retrieving revision 1.37
diff -u -3 -r1.36 -r1.37
--- comms.c 9 Dec 2003 20:25:16 -0000 1.36
+++ comms.c 11 Dec 2003 21:13:50 -0000 1.37
@@ -67,7 +67,7 @@
if (s)
{
comms_win = 0;
- sscanf((char *)s, "%*s %x", (unsigned int *)&comms_win);
+ sscanf((char *)s, "%*s %lx", &comms_win);
XFree(s);
}
else
@@ -207,7 +207,7 @@
s2[i] = ev->data.b[i];
for (i = 0; i < 12; i++)
s[i] = ev->data.b[i + 8];
- sscanf(s2, "%x", (int *)&win);
+ sscanf(s2, "%lx", &win);
cl = (Client *) FindItem(NULL, win, LIST_FINDBY_ID, LIST_TYPE_CLIENT);
if (!cl)
{
@@ -1172,7 +1172,7 @@
Window win = 0;
Background *bg;
- sscanf(s, "%*s %x %1000s", (unsigned int *)&win, w);
+ sscanf(s, "%*s %lx %1000s", &win, w);
bg = (Background *) FindItem(w, 0, LIST_FINDBY_NAME,
LIST_TYPE_BACKGROUND);
if (bg)
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/icccm.c,v
retrieving revision 1.42
retrieving revision 1.43
diff -u -3 -r1.42 -r1.43
--- icccm.c 24 Nov 2003 17:07:23 -0000 1.42
+++ icccm.c 11 Dec 2003 21:13:50 -0000 1.43
@@ -156,6 +156,7 @@
Atom a3, *prop;
unsigned long lnum, ldummy;
int num, i, del, dummy;
+ unsigned char *puc;
EDBUG(6, "ICCCM_Delete");
if (ewin->internal)
@@ -190,8 +191,10 @@
del = 0;
if (!XGetWMProtocols(disp, ewin->client.win, &prop, &num))
{
+ puc = NULL;
XGetWindowProperty(disp, ewin->client.win, a2, 0, 10, False, a2, &a3,
- &dummy, &lnum, &ldummy, (unsigned char **)&prop);
+ &dummy, &lnum, &ldummy, &puc);
+ prop = (Atom *) puc;
num = (int)lnum;
}
if (prop)
@@ -507,6 +510,7 @@
Atom a3, *prop;
unsigned long lnum, ldummy;
int num, i, foc, dummy;
+ unsigned char *puc;
EDBUG(6, "ICCCM_Focus");
if (!a1)
@@ -533,8 +537,10 @@
}
if (!XGetWMProtocols(disp, ewin->client.win, &prop, &num))
{
+ puc = NULL;
XGetWindowProperty(disp, ewin->client.win, a2, 0, 10, False, a2, &a3,
- &dummy, &lnum, &ldummy, (unsigned char **)&prop);
+ &dummy, &lnum, &ldummy, &puc);
+ prop = (Atom *) puc;
num = (int)lnum;
}
if (prop)
@@ -746,6 +752,7 @@
unsigned long lnum, ldummy;
int num, dummy;
char ok = 1;
+ unsigned char *puc;
EDBUG(6, "ICCCM_GetInfo");
if (atom_change)
@@ -987,11 +994,12 @@
if (ok)
{
num = 0;
- s = NULL;
+ puc = NULL;
if (!a2)
a2 = XInternAtom(disp, "WM_WINDOW_ROLE", False);
XGetWindowProperty(disp, ewin->client.win, a2, 0, 10, False, XA_STRING,
- &a3, &dummy, &lnum, &ldummy, (unsigned char **)&s);
+ &a3, &dummy, &lnum, &ldummy, &puc);
+ s = (char *)puc;
num = (int)lnum;
if (s)
{
@@ -1013,11 +1021,12 @@
Window w;
static Atom a = 0;
Atom a2, *prop;
- Window *cleader = NULL;
+ Window *cleader;
unsigned long lnum, ldummy;
int i, num, dummy;
static Atom a3 = 0;
char ok = 1;
+ unsigned char *puc;
EDBUG(6, "ICCCM_GetHints");
if (ewin->internal)
@@ -1172,9 +1181,10 @@
{
if (!a)
a = XInternAtom(disp, "WM_CLIENT_LEADER", False);
+ puc = NULL;
XGetWindowProperty(disp, ewin->client.win, a, 0, 0x7fffffff, False,
- XA_WINDOW, &a2, &dummy, &lnum, &ldummy,
- (unsigned char **)&cleader);
+ XA_WINDOW, &a2, &dummy, &lnum, &ldummy, &puc);
+ cleader = (Window *) puc;
if (cleader)
{
ewin->client.client_leader = *cleader;
@@ -1306,13 +1316,16 @@
ICCCM_GetMainEInfo(void)
{
Atom a, a2;
- CARD32 *c = NULL;
+ CARD32 *c;
unsigned long lnum, ldummy;
int num, dummy, i;
+ unsigned char *puc;
a = XInternAtom(disp, "ENL_INTERNAL_AREA_DATA", False);
+ puc = NULL;
XGetWindowProperty(disp, root.win, a, 0, 10, False, XA_CARDINAL, &a2,
- &dummy, &lnum, &ldummy, (unsigned char **)&c);
+ &dummy, &lnum, &ldummy, &puc);
+ c = (CARD32 *) puc;
num = (int)lnum;
if ((num > 0) && (c))
{
@@ -1326,12 +1339,12 @@
}
XFree(c);
}
- num = 0;
- c = NULL;
a = XInternAtom(disp, "ENL_INTERNAL_DESK_DATA", False);
+ puc = NULL;
XGetWindowProperty(disp, root.win, a, 0, 10, False, XA_CARDINAL, &a2,
- &dummy, &lnum, &ldummy, (unsigned char **)&c);
+ &dummy, &lnum, &ldummy, &puc);
+ c = (CARD32 *) puc;
num = (int)lnum;
if ((num > 0) && (c))
{
@@ -1345,20 +1358,25 @@
{
static Atom a = 0, aa = 0;
Atom a2;
- CARD32 *c = NULL;
- char *str = NULL;
+ CARD32 *c;
+ char *str;
unsigned long lnum, ldummy;
int num, dummy;
+ unsigned char *puc;
EDBUG(6, "ICCCM_GetEInfo");
if (ewin->internal)
EDBUG_RETURN(0);
+
if (!a)
a = XInternAtom(disp, "ENL_INTERNAL_DATA", False);
if (!aa)
aa = XInternAtom(disp, "ENL_INTERNAL_DATA_BORDER", False);
+
+ puc = NULL;
XGetWindowProperty(disp, ewin->client.win, a, 0, 10, True, XA_CARDINAL, &a2,
- &dummy, &lnum, &ldummy, (unsigned char **)&c);
+ &dummy, &lnum, &ldummy, &puc);
+ c = (CARD32 *) puc;
num = (int)lnum;
if ((num >= 8) && (c))
{
@@ -1383,11 +1401,12 @@
ewin->client.w = c[6];
ewin->client.h = c[7];
}
+
+ puc = NULL;
XGetWindowProperty(disp, ewin->client.win, aa, 0, 0xffff, True,
- XA_STRING, &a2, &dummy, &lnum, &ldummy,
- (unsigned char **)&str);
+ XA_STRING, &a2, &dummy, &lnum, &ldummy, &puc);
+ str = (char *)puc;
num = (int)lnum;
-
if ((num > 0) && (str))
{
Border *b = NULL;
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/ipc.c,v
retrieving revision 1.120
retrieving revision 1.121
diff -u -3 -r1.120 -r1.121
--- ipc.c 9 Dec 2003 20:35:14 -0000 1.120
+++ ipc.c 11 Dec 2003 21:13:50 -0000 1.121
@@ -691,7 +691,7 @@
Window win = 0;
EWin *ewin;
- sscanf(params, "%x", (int *)&win);
+ sscanf(params, "%lx", &win);
ewin = FindItem(NULL, (int)win, LIST_FINDBY_ID, LIST_TYPE_EWIN);
if (ewin)
{
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/mwm.c,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -3 -r1.17 -r1.18
--- mwm.c 5 Nov 2003 17:24:45 -0000 1.17
+++ mwm.c 11 Dec 2003 21:13:50 -0000 1.18
@@ -71,6 +71,7 @@
Atom a1, a2;
unsigned long num, end;
MWMHints *mwmhints;
+ unsigned char *puc;
EDBUG(6, "MWM_GetHints");
if (ewin->internal)
@@ -96,9 +97,10 @@
ewin->client.mwm_func_maximize = 1;
ewin->client.mwm_func_close = 1;
a1 = XInternAtom(disp, "_MOTIF_WM_HINTS", False);
- mwmhints = NULL;
+ puc = NULL;
XGetWindowProperty(disp, ewin->client.win, a1, 0, 20, False, a1, &a2, &fmt,
- &num, &end, (unsigned char **)&mwmhints);
+ &num, &end, &puc);
+ mwmhints = (MWMHints *) puc;
if (mwmhints)
{
if (num < PROP_MWM_HINTS_ELEMENTS)
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/setup.c,v
retrieving revision 1.96
retrieving revision 1.97
diff -u -3 -r1.96 -r1.97
--- setup.c 15 Nov 2003 22:27:17 -0000 1.96
+++ setup.c 11 Dec 2003 21:13:50 -0000 1.97
@@ -690,11 +690,13 @@
Atom aa;
int format_ret;
unsigned long bytes_after, num_ret;
+ unsigned char *puc;
- retval = NULL;
+ puc = NULL;
XGetWindowProperty(disp, root.win, a, 0, 0x7fffffff, True,
XA_CARDINAL, &aa, &format_ret, &num_ret,
- &bytes_after, (unsigned char **)(&retval));
+ &bytes_after, &puc);
+ retval = (Window *) puc;
XSync(disp, False);
if (retval)
break;
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/x.c,v
retrieving revision 1.58
retrieving revision 1.59
diff -u -3 -r1.58 -r1.59
--- x.c 4 Dec 2003 19:02:03 -0000 1.58
+++ x.c 11 Dec 2003 21:13:50 -0000 1.59
@@ -76,12 +76,15 @@
static EXID *
FindXID(Window win)
{
- EXID *xid = NULL;
+ EXID *xid;
+ XPointer xp;
if (xid_context == 0)
xid_context = XUniqueContext();
- if (XFindContext(disp, win, xid_context, (XPointer *) & xid) == XCNOENT)
- xid = NULL;
+ xp = NULL;
+ if (XFindContext(disp, win, xid_context, &xp) == XCNOENT)
+ xp = NULL;
+ xid = (EXID *) xp;
return xid;
}
-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills. Sign up for IBM's
Free Linux Tutorials. Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
_______________________________________________
enlightenment-cvs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs