libUPnP  1.14.19
sysdep.h
Go to the documentation of this file.
1 #ifndef SYSDEP_H
2 #define SYSDEP_H
3 
4 /*
5  * Copyright (c) 1990- 1993, 1996 Open Software Foundation, Inc.
6  * Copyright (c) 1989 by Hewlett-Packard Company, Palo Alto, Ca. &
7  * Digital Equipment Corporation, Maynard, Mass.
8  * Copyright (c) 1998 Microsoft.
9  * To anyone who acknowledges that this file is provided "AS IS"
10  * without any express or implied warranty: permission to use, copy,
11  * modify, and distribute this file for any purpose is hereby
12  * granted without fee, provided that the above copyright notices and
13  * this notice appears in all source code copies, and that none of
14  * the names of Open Software Foundation, Inc., Hewlett-Packard
15  * Company, or Digital Equipment Corporation be used in advertising
16  * or publicity pertaining to distribution of the software without
17  * specific, written prior permission. Neither Open Software
18  * Foundation, Inc., Hewlett-Packard Company, Microsoft, nor Digital Equipment
19  * Corporation makes any representations about the suitability of
20  * this software for any purpose.
21  */
22 
27 #include "ithread.h"
28 
29 /* change to point to where MD5 .h's live */
30 /* get MD5 sample implementation from RFC 1321 */
31 #include "md5.h"
32 
33 #include "UpnpStdInt.h"
34 
35 #include <sys/types.h>
36 
37 #ifdef _WIN32
38  /* Do not #include <sys/time.h> */
39 #else
40  #include <sys/time.h>
41 #endif
42 
45 #define UUIDS_PER_TICK 1024
46 
48 extern ithread_mutex_t gUUIDMutex;
49 
50 #define UUIDLock() ithread_mutex_lock(&gUUIDMutex)
51 #define UUIDUnlock() ithread_mutex_unlock(&gUUIDMutex)
52 
53 typedef uint64_t uuid_time_t;
54 
55 typedef struct
56 {
57  char nodeID[6];
58 } uuid_node_t;
59 
61 void get_system_time(uuid_time_t *uuid_time);
62 void get_random_info(unsigned char seed[16]);
63 
64 #endif /* SYSDEP_H */
Definition: sysdep.h:55
void get_system_time(uuid_time_t *uuid_time)
System dependent call to get the current system time.
Definition: sysdep.c:96
ithread_mutex_t gUUIDMutex
Definition: upnpapi.c:123
void get_ieee_node_identifier(uuid_node_t *node)
System dependent call to get IEEE node ID.
Definition: sysdep.c:42