update ocaml-ivy for 64 bit

This commit is contained in:
Eric Parsonage
2010-11-19 12:24:15 +00:00
committed by Felix Ruess
parent fc8a242467
commit 0fcd31ebc7
3 changed files with 9 additions and 9 deletions
+1 -1
View File
@@ -38,6 +38,6 @@ value ivy_GtkchannelSetUp(value fd, value closure_name)
value ivy_GtkchannelClose(value ch)
{
IvyChannelRemove((Channel)Int_val(ch));
IvyChannelRemove((Channel)Long_val(ch));
return Val_unit;
}
+5 -5
View File
@@ -54,29 +54,29 @@ void ClosureCallback(IvyClientPtr app, void *closure, int argc, char **argv)
/* Copie de argv dans t avec ajout d'un pointeur nul a la fin */
for(i=0; i < argc; i++) t[i] = argv[i];
t[argc] = (char*)0L;
callback2(*(value*)closure, Val_int((int)app), copy_string_array((char const **)t));
callback2(*(value*)closure, Val_long(app), copy_string_array((char const **)t));
}
value ivy_bindMsg(value cb_name, value regexp)
{
value * closure = caml_named_value(String_val(cb_name));
MsgRcvPtr id = IvyBindMsg(ClosureCallback, (void*)closure, String_val(regexp));
return Val_int((int)id);
return Val_long(id);
}
value ivy_unbindMsg(value id)
{
IvyUnbindMsg((MsgRcvPtr)Int_val(id));
IvyUnbindMsg((MsgRcvPtr)Long_val(id));
return Val_unit;
}
value ivy_name_of_client(value c)
{
return copy_string(IvyGetApplicationName((IvyClientPtr)Int_val(c)));
return copy_string(IvyGetApplicationName((IvyClientPtr)Long_val(c)));
}
value ivy_host_of_client(value c)
{
return copy_string(IvyGetApplicationHost((IvyClientPtr)Int_val(c)));
return copy_string(IvyGetApplicationHost((IvyClientPtr)Long_val(c)));
}
void cb_delete_channel(void *delete_read)
+3 -3
View File
@@ -25,7 +25,7 @@ value ivy_mainLoop(value unit)
void timer_cb(TimerId id, void *data, unsigned long delta)
{
value closure = *(value*)data;
callback(closure, Val_int((int) id));
callback(closure, Val_long((int) id));
}
value ivy_timerRepeatafter(value nb_ticks,value delay, value closure_name)
@@ -58,13 +58,13 @@ value ivy_channelSetUp(value fd, value closure_name)
value ivy_timerRemove(value t)
{
TimerRemove((TimerId)Int_val(t));
TimerRemove((TimerId)Long_val(t));
return Val_unit;
}
value ivy_channelClose(value ch)
{
IvyChannelRemove((Channel)Int_val(ch));
IvyChannelRemove((Channel)Long_val(ch));
return Val_unit;
}