src/server/util/systems.h

changeset 24
1a7853a4257e
parent 14
b8bf95b39952
child 106
b122f34ddc80
equal deleted inserted replaced
23:a2c8fc23c90e 24:1a7853a4257e
32 */ 32 */
33 33
34 #ifndef BASE_SYSTEMS_H 34 #ifndef BASE_SYSTEMS_H
35 #define BASE_SYSTEMS_H 35 #define BASE_SYSTEMS_H
36 36
37 #include <nspr.h> 37 //include <nspr.h>
38 #include <inttypes.h>
38 39
39 #ifndef NOINTNSAPI 40 #ifndef NOINTNSAPI
40 #define INTNSAPI 41 #define INTNSAPI
41 #endif /* !NOINTNSAPI */ 42 #endif /* !NOINTNSAPI */
42 43
50 51
51 /* --- Begin common definitions for all supported platforms --- */ 52 /* --- Begin common definitions for all supported platforms --- */
52 53
53 #define DAEMON_ANY 54 #define DAEMON_ANY
54 #define DAEMON_STATS 55 #define DAEMON_STATS
56
57 /* new types */
58 typedef int PRBool;
59 #define PR_TRUE 1
60 #define PR_FALSE 0
61 /* end new types */
55 62
56 /* --- End common definitions for all supported platforms --- */ 63 /* --- End common definitions for all supported platforms --- */
57 64
58 /* --- Begin platform-specific definitions --- */ 65 /* --- Begin platform-specific definitions --- */
59 66
491 /* 498 /*
492 * These types have to be defined early, because they are defined 499 * These types have to be defined early, because they are defined
493 * as (void *) in the public API. 500 * as (void *) in the public API.
494 */ 501 */
495 502
496 #ifndef SYS_FILE_T 503 /* TODO: remove */
497 typedef PRFileDesc *SYS_FILE; 504 //ifndef SYS_FILE_T
498 #define SYS_FILE_T PRFileDesc * 505 //typedef PRFileDesc *SYS_FILE;
499 #endif /* !SYS_FILE_T */ 506 //define SYS_FILE_T PRFileDesc *
500 507 //endif /* !SYS_FILE_T */
501 #ifndef SYS_NETFD_T 508
502 typedef PRFileDesc *SYS_NETFD; 509 //ifndef SYS_NETFD_T
503 #define SYS_NETFD_T PRFileDesc * 510 //typedef PRFileDesc *SYS_NETFD;
504 #endif /* !SYS_NETFD_T */ 511 //define SYS_NETFD_T PRFileDesc *
512 //endif /* !SYS_NETFD_T */
505 513
506 #ifdef SEM_WIN32 514 #ifdef SEM_WIN32
507 515
508 typedef HANDLE SEMAPHORE; 516 typedef HANDLE SEMAPHORE;
509 #define SEMAPHORE_T HANDLE 517 #define SEMAPHORE_T HANDLE
522 #define SEM_ERROR ((void *)(-1)) 530 #define SEM_ERROR ((void *)(-1))
523 typedef void* SEMAPHORE_T; 531 typedef void* SEMAPHORE_T;
524 532
525 #else /* ! SEM_WIN32 */ 533 #else /* ! SEM_WIN32 */
526 534
527 typedef int SEMAPHORE; 535 // TODO
528 #define SEMAPHORE_T int 536 //typedef int SEMAPHORE;
529 #define SEM_ERROR -1 537 //define SEMAPHORE_T int
538 //define SEM_ERROR -1
530 539
531 #endif /* SEM_WIN32 */ 540 #endif /* SEM_WIN32 */
532 541
533 #endif /* !APSTUDIO_READONLY_SYMBOLS */ 542 #endif /* !APSTUDIO_READONLY_SYMBOLS */
534 543

mercurial