[ekg2-commit] r3847 - trunk/plugins/xmsg: trunk/plugins/xmsg/xmsg.c
SVN commit
svn w toxygen.net
Pią, 7 Mar 2008, 18:32:39 CET
Author: peres
Date: 2008-03-07 18:32:38 +0100 (Fri, 07 Mar 2008)
New Revision: 3847
Modified:
trunk/plugins/xmsg/xmsg.c
Log:
long int shall have same size as void* on both 64-bit and 32-bit x86.
But more portable resolution would be appreciated.
Modified: trunk/plugins/xmsg/xmsg.c
===================================================================
--- trunk/plugins/xmsg/xmsg.c 2008-03-06 11:07:17 UTC (rev 3846)
+++ trunk/plugins/xmsg/xmsg.c 2008-03-07 17:32:38 UTC (rev 3847)
@@ -402,10 +402,10 @@
}
#ifdef HAVE_INOTIFY
- if (session->priv && inotify_rm_watch(in_fd, (uint32_t) session->priv))
+ if (session->priv && inotify_rm_watch(in_fd, (long int) session->priv))
xdebug2(DEBUG_ERROR, "rmwatch failed");
else
- xdebug("inotify watch removed: %d", (uint32_t) session->priv);
+ xdebug("inotify watch removed: %d", (long int) session->priv);
#endif /*HAVE_INOTIFY*/
return 0;
@@ -438,7 +438,7 @@
for (sp = sessions; sp; sp = sp->next) {
s = sp->data;
- if (s && (s->priv == (void*) evp->wd) && !xstrncasecmp(session_uid_get(s), "xmsg:", 5))
+ if (s && (s->priv == (void*) (long int) evp->wd) && !xstrncasecmp(session_uid_get(s), "xmsg:", 5))
break;
}
@@ -524,10 +524,10 @@
}
#ifdef HAVE_INOTIFY
- if ((s->priv = (void*) inotify_add_watch(in_fd, dir, (IN_CLOSE_WRITE|IN_MOVED_TO|IN_ONLYDIR))) == (void*) -1)
+ if ((s->priv = (void*) (long int) inotify_add_watch(in_fd, dir, (IN_CLOSE_WRITE|IN_MOVED_TO|IN_ONLYDIR))) == (void*) -1)
xerrn("unable to add inotify watch");
- xdebug("inotify watch added: %d", (uint32_t) s->priv);
+ xdebug("inotify watch added: %d", (long int) s->priv);
#endif /*HAVE_INOTIFY*/
return 0;
Więcej informacji o liście dyskusyjnej ekg2-commit