summaryrefslogtreecommitdiff
path: root/src/glut/glx/glut_event.c
diff options
context:
space:
mode:
authorJouk Jansen <joukj@hrem.stm.tudelft.nl>2001-02-09 12:19:17 +0000
committerJosé Fonseca <jfonseca@vmware.com>2011-07-11 20:03:29 +0100
commit12cfa812953aaae3f3a65f76f58db811f03c9cde (patch)
tree49302aed3f528a22bddead0b2554582b4050df4d /src/glut/glx/glut_event.c
parent80259fed3ffe98c98f9ff8ff848a1ae155739830 (diff)
downloadglut-12cfa812953aaae3f3a65f76f58db811f03c9cde.tar.gz
Committing in .
Modified Files: Mesa/src-glut/glut_event.c Mesa/src-glut/glut_get.c Mesa/src-glut/glut_init.c Mesa/src-glut/glutint.h Patch for compilation on very old VMS (version 6.2 and earlier) ----------------------------------------------------------------------
Diffstat (limited to 'src/glut/glx/glut_event.c')
-rw-r--r--src/glut/glx/glut_event.c30
1 files changed, 21 insertions, 9 deletions
diff --git a/src/glut/glx/glut_event.c b/src/glut/glx/glut_event.c
index f4463de..d2c2c48 100644
--- a/src/glut/glx/glut_event.c
+++ b/src/glut/glx/glut_event.c
@@ -64,18 +64,18 @@
# endif
#endif /* !_WIN32 */
+#include "glutint.h"
+
#if defined(__vms) && ( __VMS_VER < 70000000 )
#include <ssdef.h>
#include <psldef.h>
extern int SYS$CLREF(int efn);
-extern int SYS$SETIMR(unsigned int efn, struct timeval *timeout, void *ast,
+extern int SYS$SETIMR(unsigned int efn, struct timeval6 *timeout, void *ast,
unsigned int request_id, unsigned int flags);
extern int SYS$WFLOR(unsigned int efn, unsigned int mask);
extern int SYS$CANTIM(unsigned int request_id, unsigned int mode);
#endif /* __vms, VMs 6.2 or earlier */
-#include "glutint.h"
-
static GLUTtimer *freeTimerList = NULL;
GLUTidleCB __glutIdleFunc = NULL;
@@ -114,8 +114,12 @@ glutTimerFunc(unsigned int interval, GLUTtimerCB timerFunc, int value)
{
GLUTtimer *timer, *other;
GLUTtimer **prevptr;
- struct timeval now;
-
+#ifdef OLD_VMS
+ struct timeval6 now;
+#else
+ struct timeval now;
+#endif
+
if (!timerFunc)
return;
@@ -156,8 +160,12 @@ glutTimerFunc(unsigned int interval, GLUTtimerCB timerFunc, int value)
void
handleTimeouts(void)
{
- struct timeval now;
- GLUTtimer *timer;
+#ifdef OLD_VMS
+ struct timeval6 now;
+#else
+ struct timeval now;
+#endif
+ GLUTtimer *timer;
/* Assumption is that __glutTimerList is already determined
to be non-NULL. */
@@ -839,7 +847,7 @@ static void
waitForSomething(void)
{
#if defined(__vms) && ( __VMS_VER < 70000000 )
- static struct timeval zerotime =
+ static struct timeval6 zerotime =
{0};
unsigned int timer_efn;
#define timer_id 'glut' /* random :-) number */
@@ -851,7 +859,11 @@ waitForSomething(void)
fd_set fds;
#endif
#endif
- struct timeval now, timeout, waittime;
+#ifdef OLD_VMS
+ struct timeval6 now, timeout, waittime;
+#else
+ struct timeval now, timeout, waittime;
+#endif
#if !defined(_WIN32)
int rc;
#endif