From 1567ea408407a13cf334a2a781b68fce8c63ae3b Mon Sep 17 00:00:00 2001 From: richard Date: Tue, 26 Jan 1999 09:00:20 +0000 Subject: [PATCH] NSThread bugfix in sleeping git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@3591 72102866-910b-0410-8b05-ffd578937521 --- ChangeLog | 5 +++++ Source/NSConnection.m | 2 +- Source/NSThread.m | 4 ++-- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index b42be460a..42d7f944f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Tue Jan 26 8:15:00 1999 Richard Frith-Macdonald + + * src/NSThread.m: ([-sleepUntilDate:]) cast argument of usleep() to + be integer rather than float - suggested by stark@easynet.fr + Sun Jan 24 8:50:00 1999 Richard Frith-Macdonald * src/NSConnection.m: Preliminary work for handling DO between diff --git a/Source/NSConnection.m b/Source/NSConnection.m index b0e330b9b..6ecea9e1d 100644 --- a/Source/NSConnection.m +++ b/Source/NSConnection.m @@ -1575,7 +1575,7 @@ static int messages_received_count; /* xxx We should make sure that TARGET is a valid object. */ /* Not actually a Proxy, but we avoid the warnings "id" would have made. */ - m = class_get_instance_method((o)->isa, sel); + m = class_get_instance_method(((NSDistantObject*)o)->isa, sel); /* Perhaps I need to be more careful in the line above to get the version of the method types that has the type qualifiers in it. Search the protocols list. */ diff --git a/Source/NSThread.m b/Source/NSThread.m index 08671d7c9..a5283a3b6 100644 --- a/Source/NSThread.m +++ b/Source/NSThread.m @@ -196,9 +196,9 @@ void gnustep_base_thread_callback() while (delay > 0) { #ifdef HAVE_USLEEP - usleep (delay*1000000); + usleep ((int)(delay*1000000)); #else - sleep (delay); + sleep ((int)delay); #endif delay = [date timeIntervalSinceNow]; }