projects
/
open-adventure.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
gitignore the database compilation products.
[open-adventure.git]
/
misc.c
diff --git
a/misc.c
b/misc.c
index 111848e1d5231eb7a9d00b59f3b9dfe4485e9bc4..1e72ba7cb2bc3dc90460f4d0d2bfbb1ba07fdca0 100644
(file)
--- a/
misc.c
+++ b/
misc.c
@@
-2,6
+2,7
@@
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
+#include <sys/time.h>
#include "main.h"
#include "share.h" /* for SETUP */
#include "misc.h"
#include "main.h"
#include "share.h" /* for SETUP */
#include "misc.h"
@@
-1002,5
+1003,11
@@
L30: if(IN)IGNORE(fread(ARR,sizeof(long),250,F));
+void DATIME(long* D, long* T) {
+ struct timeval tv;
+ gettimeofday(&tv, NULL);
+ *D = (long) tv.tv_sec;
+ *T = (long) tv.tv_usec;
+}
long fIABS(N)long N; {return(N<0? -N : N);}
long fMOD(N,M)long N, M; {return(N%M);}
long fIABS(N)long N; {return(N<0? -N : N);}
long fMOD(N,M)long N, M; {return(N%M);}