* Streamlined some variables to be of the same type regardless of the architecture used

git-svn-id: svn://svn.code.sf.net/p/libkqueue/code/trunk@524 fb4e3144-bc1c-4b72-a658-5bcd248dd7f7
This commit is contained in:
marius 2011-06-13 19:27:44 +00:00
parent 8cbdb46b43
commit f786d2e798
4 changed files with 5 additions and 5 deletions

View File

@ -120,7 +120,7 @@ knote_delete(struct filter *filt, struct knote *kn)
}
struct knote *
knote_lookup(struct filter *filt, short ident)
knote_lookup(struct filter *filt, uintptr_t ident)
{
struct knote query;
struct knote *ent = NULL;

View File

@ -185,7 +185,7 @@ extern const struct kqueue_vtable kqops;
/*
* knote internal API
*/
struct knote * knote_lookup(struct filter *, short);
struct knote * knote_lookup(struct filter *, uintptr_t);
//DEADWOOD: struct knote * knote_get_by_data(struct filter *filt, intptr_t);
struct knote * knote_new(void);
#define knote_retain(kn) atomic_inc(&kn->kn_ref)

View File

@ -224,7 +224,7 @@ windows_get_descriptor_type(struct knote *kn)
/*
* Test if the descriptor is a socket.
*/
if (fstat(kn->kev.ident, &sb) == 0) {
if (fstat( (int)kn->kev.ident, &sb) == 0) {
dbg_printf("HANDLE %d appears to a be regular file", kn->kev.ident);
kn->kn_flags |= KNFL_REGULAR_FILE;
} else {

View File

@ -18,7 +18,7 @@
/* Convert milliseconds into negative increments of 100-nanoseconds */
static void
convert_msec_to_filetime(LARGE_INTEGER *dst, int src)
convert_msec_to_filetime(LARGE_INTEGER *dst, intptr_t src)
{
dst->QuadPart = -((int64_t) src * 1000 * 10);
}
@ -130,7 +130,7 @@ evfilt_timer_knote_create(struct filter *filt, struct knote *kn)
convert_msec_to_filetime(&liDueTime, kn->kev.data);
// XXX-FIXME add completion routine to this call
if (!SetWaitableTimer(th, &liDueTime, (kn->kev.flags & EV_ONESHOT) ? 0 : kn->kev.data, NULL, NULL, FALSE)) {
if (!SetWaitableTimer(th, &liDueTime, (LONG)( (kn->kev.flags & EV_ONESHOT) ? 0 : kn->kev.data ), NULL, NULL, FALSE)) {
dbg_lasterror("SetWaitableTimer()");
CloseHandle(th);
return (-1);