diff options
author | Steve Bennett <steveb@workware.net.au> | 2017-10-16 09:00:23 +1000 |
---|---|---|
committer | Steve Bennett <steveb@workware.net.au> | 2017-10-16 09:00:23 +1000 |
commit | b04d7cc4745a9fefc539ad9ee8888d2733811778 (patch) | |
tree | 038bfa9d12db818fd58575b99758b3d27ffb5146 /jim-eventloop.c | |
parent | 905198322995166a2d84fd0de3d0b8db43425a0a (diff) | |
download | jimtcl-b04d7cc4745a9fefc539ad9ee8888d2733811778.zip jimtcl-b04d7cc4745a9fefc539ad9ee8888d2733811778.tar.gz jimtcl-b04d7cc4745a9fefc539ad9ee8888d2733811778.tar.bz2 |
after: Need to initialise 'ms'
Also fix a warning on Windows
Signed-off-by: Steve Bennett <steveb@workware.net.au>
Diffstat (limited to 'jim-eventloop.c')
-rw-r--r-- | jim-eventloop.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/jim-eventloop.c b/jim-eventloop.c index 5735e97..78aae12 100644 --- a/jim-eventloop.c +++ b/jim-eventloop.c @@ -54,8 +54,10 @@ #if defined(__MINGW32__) #include <windows.h> #include <winsock.h> +#ifndef HAVE_USLEEP #define usleep(US) Sleep((US) / 1000) #define HAVE_USLEEP +#endif #else #include <sys/types.h> #ifdef HAVE_SYS_SELECT_H @@ -628,7 +630,7 @@ static void JimAfterTimeEventFinalizer(Jim_Interp *interp, void *clientData) static int JimELAfterCommand(Jim_Interp *interp, int argc, Jim_Obj *const *argv) { Jim_EventLoop *eventLoop = Jim_CmdPrivData(interp); - double ms; + double ms = 0; jim_wide id; Jim_Obj *objPtr, *idObjPtr; static const char * const options[] = { |