1 /* Adapted from the sources of the Apache Portable Runtime library version 1.5.1:
\r
2 * https://apr.apache.org/
\r
10 # 1 "<command line>" 1
\r
18 # 1 "./../test/abts.h" 1
\r
19 # 21 "./../test/abts.h"
\r
20 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stdarg.h" 1 3
\r
21 # 30 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stdarg.h" 3
\r
22 typedef __builtin_va_list va_list;
\r
23 # 50 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stdarg.h" 3
\r
24 typedef __builtin_va_list __gnuc_va_list;
\r
25 # 22 "./../test/abts.h" 2
\r
26 # 1 "/usr/include/stdio.h" 1 3 4
\r
27 # 27 "/usr/include/stdio.h" 3 4
\r
28 # 1 "/usr/include/features.h" 1 3 4
\r
29 # 352 "/usr/include/features.h" 3 4
\r
30 # 1 "/usr/include/stdc-predef.h" 1 3 4
\r
31 # 353 "/usr/include/features.h" 2 3 4
\r
32 # 374 "/usr/include/features.h" 3 4
\r
33 # 1 "/usr/include/x86_64-linux-gnu/sys/cdefs.h" 1 3 4
\r
34 # 385 "/usr/include/x86_64-linux-gnu/sys/cdefs.h" 3 4
\r
35 # 1 "/usr/include/x86_64-linux-gnu/bits/wordsize.h" 1 3 4
\r
36 # 386 "/usr/include/x86_64-linux-gnu/sys/cdefs.h" 2 3 4
\r
37 # 375 "/usr/include/features.h" 2 3 4
\r
38 # 398 "/usr/include/features.h" 3 4
\r
39 # 1 "/usr/include/x86_64-linux-gnu/gnu/stubs.h" 1 3 4
\r
40 # 10 "/usr/include/x86_64-linux-gnu/gnu/stubs.h" 3 4
\r
41 # 1 "/usr/include/x86_64-linux-gnu/gnu/stubs-64.h" 1 3 4
\r
42 # 11 "/usr/include/x86_64-linux-gnu/gnu/stubs.h" 2 3 4
\r
43 # 399 "/usr/include/features.h" 2 3 4
\r
44 # 28 "/usr/include/stdio.h" 2 3 4
\r
50 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stddef.h" 1 3 4
\r
51 # 58 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stddef.h" 3 4
\r
52 typedef long unsigned int size_t;
\r
53 # 34 "/usr/include/stdio.h" 2 3 4
\r
55 # 1 "/usr/include/x86_64-linux-gnu/bits/types.h" 1 3 4
\r
56 # 27 "/usr/include/x86_64-linux-gnu/bits/types.h" 3 4
\r
57 # 1 "/usr/include/x86_64-linux-gnu/bits/wordsize.h" 1 3 4
\r
58 # 28 "/usr/include/x86_64-linux-gnu/bits/types.h" 2 3 4
\r
61 typedef unsigned char __u_char;
\r
62 typedef unsigned short int __u_short;
\r
63 typedef unsigned int __u_int;
\r
64 typedef unsigned long int __u_long;
\r
67 typedef signed char __int8_t;
\r
68 typedef unsigned char __uint8_t;
\r
69 typedef signed short int __int16_t;
\r
70 typedef unsigned short int __uint16_t;
\r
71 typedef signed int __int32_t;
\r
72 typedef unsigned int __uint32_t;
\r
74 typedef signed long int __int64_t;
\r
75 typedef unsigned long int __uint64_t;
\r
83 typedef long int __quad_t;
\r
84 typedef unsigned long int __u_quad_t;
\r
85 # 121 "/usr/include/x86_64-linux-gnu/bits/types.h" 3 4
\r
86 # 1 "/usr/include/x86_64-linux-gnu/bits/typesizes.h" 1 3 4
\r
87 # 122 "/usr/include/x86_64-linux-gnu/bits/types.h" 2 3 4
\r
90 typedef unsigned long int __dev_t;
\r
91 typedef unsigned int __uid_t;
\r
92 typedef unsigned int __gid_t;
\r
93 typedef unsigned long int __ino_t;
\r
94 typedef unsigned long int __ino64_t;
\r
95 typedef unsigned int __mode_t;
\r
96 typedef unsigned long int __nlink_t;
\r
97 typedef long int __off_t;
\r
98 typedef long int __off64_t;
\r
99 typedef int __pid_t;
\r
100 typedef struct { int __val[2]; } __fsid_t;
\r
101 typedef long int __clock_t;
\r
102 typedef unsigned long int __rlim_t;
\r
103 typedef unsigned long int __rlim64_t;
\r
104 typedef unsigned int __id_t;
\r
105 typedef long int __time_t;
\r
106 typedef unsigned int __useconds_t;
\r
107 typedef long int __suseconds_t;
\r
109 typedef int __daddr_t;
\r
110 typedef int __key_t;
\r
113 typedef int __clockid_t;
\r
116 typedef void * __timer_t;
\r
119 typedef long int __blksize_t;
\r
124 typedef long int __blkcnt_t;
\r
125 typedef long int __blkcnt64_t;
\r
128 typedef unsigned long int __fsblkcnt_t;
\r
129 typedef unsigned long int __fsblkcnt64_t;
\r
132 typedef unsigned long int __fsfilcnt_t;
\r
133 typedef unsigned long int __fsfilcnt64_t;
\r
136 typedef long int __fsword_t;
\r
138 typedef long int __ssize_t;
\r
141 typedef long int __syscall_slong_t;
\r
143 typedef unsigned long int __syscall_ulong_t;
\r
147 typedef __off64_t __loff_t;
\r
148 typedef __quad_t *__qaddr_t;
\r
149 typedef char *__caddr_t;
\r
152 typedef long int __intptr_t;
\r
155 typedef unsigned int __socklen_t;
\r
156 # 36 "/usr/include/stdio.h" 2 3 4
\r
169 typedef struct _IO_FILE FILE;
\r
170 # 64 "/usr/include/stdio.h" 3 4
\r
171 typedef struct _IO_FILE __FILE;
\r
172 # 74 "/usr/include/stdio.h" 3 4
\r
173 # 1 "/usr/include/libio.h" 1 3 4
\r
174 # 31 "/usr/include/libio.h" 3 4
\r
175 # 1 "/usr/include/_G_config.h" 1 3 4
\r
176 # 15 "/usr/include/_G_config.h" 3 4
\r
177 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stddef.h" 1 3 4
\r
178 # 16 "/usr/include/_G_config.h" 2 3 4
\r
183 # 1 "/usr/include/wchar.h" 1 3 4
\r
184 # 82 "/usr/include/wchar.h" 3 4
\r
191 unsigned int __wch;
\r
198 # 21 "/usr/include/_G_config.h" 2 3 4
\r
202 __mbstate_t __state;
\r
207 __mbstate_t __state;
\r
209 # 32 "/usr/include/libio.h" 2 3 4
\r
210 # 144 "/usr/include/libio.h" 3 4
\r
211 struct _IO_jump_t; struct _IO_FILE;
\r
212 # 154 "/usr/include/libio.h" 3 4
\r
213 typedef void _IO_lock_t;
\r
219 struct _IO_marker {
\r
220 struct _IO_marker *_next;
\r
221 struct _IO_FILE *_sbuf;
\r
226 # 177 "/usr/include/libio.h" 3 4
\r
230 enum __codecvt_result
\r
237 # 245 "/usr/include/libio.h" 3 4
\r
244 char* _IO_read_ptr;
\r
245 char* _IO_read_end;
\r
246 char* _IO_read_base;
\r
247 char* _IO_write_base;
\r
248 char* _IO_write_ptr;
\r
249 char* _IO_write_end;
\r
250 char* _IO_buf_base;
\r
253 char *_IO_save_base;
\r
254 char *_IO_backup_base;
\r
255 char *_IO_save_end;
\r
257 struct _IO_marker *_markers;
\r
259 struct _IO_FILE *_chain;
\r
267 __off_t _old_offset;
\r
271 unsigned short _cur_column;
\r
272 signed char _vtable_offset;
\r
278 # 293 "/usr/include/libio.h" 3 4
\r
280 # 302 "/usr/include/libio.h" 3 4
\r
289 char _unused2[15 * sizeof (int) - 4 * sizeof (void *) - sizeof (size_t)];
\r
294 typedef struct _IO_FILE _IO_FILE;
\r
297 struct _IO_FILE_plus;
\r
299 extern struct _IO_FILE_plus _IO_2_1_stdin_;
\r
300 extern struct _IO_FILE_plus _IO_2_1_stdout_;
\r
301 extern struct _IO_FILE_plus _IO_2_1_stderr_;
\r
302 # 338 "/usr/include/libio.h" 3 4
\r
303 typedef __ssize_t __io_read_fn (void *__cookie, char *__buf, size_t __nbytes);
\r
311 typedef __ssize_t __io_write_fn (void *__cookie, const char *__buf,
\r
320 typedef int __io_seek_fn (void *__cookie, __off64_t *__pos, int __w);
\r
323 typedef int __io_close_fn (void *__cookie);
\r
324 # 390 "/usr/include/libio.h" 3 4
\r
325 extern int __underflow (_IO_FILE *);
\r
326 extern int __uflow (_IO_FILE *);
\r
327 extern int __overflow (_IO_FILE *, int);
\r
328 # 434 "/usr/include/libio.h" 3 4
\r
329 extern int _IO_getc (_IO_FILE *__fp);
\r
330 extern int _IO_putc (int __c, _IO_FILE *__fp);
\r
331 extern int _IO_feof (_IO_FILE *__fp) __attribute__ ((__nothrow__ ));
\r
332 extern int _IO_ferror (_IO_FILE *__fp) __attribute__ ((__nothrow__ ));
\r
334 extern int _IO_peekc_locked (_IO_FILE *__fp);
\r
340 extern void _IO_flockfile (_IO_FILE *) __attribute__ ((__nothrow__ ));
\r
341 extern void _IO_funlockfile (_IO_FILE *) __attribute__ ((__nothrow__ ));
\r
342 extern int _IO_ftrylockfile (_IO_FILE *) __attribute__ ((__nothrow__ ));
\r
343 # 464 "/usr/include/libio.h" 3 4
\r
344 extern int _IO_vfscanf (_IO_FILE * __restrict, const char * __restrict,
\r
345 __gnuc_va_list, int *__restrict);
\r
346 extern int _IO_vfprintf (_IO_FILE *__restrict, const char *__restrict,
\r
348 extern __ssize_t _IO_padn (_IO_FILE *, int, __ssize_t);
\r
349 extern size_t _IO_sgetn (_IO_FILE *, void *, size_t);
\r
351 extern __off64_t _IO_seekoff (_IO_FILE *, __off64_t, int, int);
\r
352 extern __off64_t _IO_seekpos (_IO_FILE *, __off64_t, int);
\r
354 extern void _IO_free_backup_area (_IO_FILE *) __attribute__ ((__nothrow__ ));
\r
355 # 75 "/usr/include/stdio.h" 2 3 4
\r
360 typedef __gnuc_va_list va_list;
\r
361 # 90 "/usr/include/stdio.h" 3 4
\r
362 typedef __off_t off_t;
\r
363 # 102 "/usr/include/stdio.h" 3 4
\r
364 typedef __ssize_t ssize_t;
\r
372 typedef _G_fpos_t fpos_t;
\r
373 # 164 "/usr/include/stdio.h" 3 4
\r
374 # 1 "/usr/include/x86_64-linux-gnu/bits/stdio_lim.h" 1 3 4
\r
375 # 165 "/usr/include/stdio.h" 2 3 4
\r
379 extern struct _IO_FILE *stdin;
\r
380 extern struct _IO_FILE *stdout;
\r
381 extern struct _IO_FILE *stderr;
\r
389 extern int remove (const char *__filename) __attribute__ ((__nothrow__ ));
\r
391 extern int rename (const char *__old, const char *__new) __attribute__ ((__nothrow__ ));
\r
396 extern int renameat (int __oldfd, const char *__old, int __newfd,
\r
397 const char *__new) __attribute__ ((__nothrow__ ));
\r
398 # 195 "/usr/include/stdio.h" 3 4
\r
399 extern FILE *tmpfile (void) ;
\r
400 # 209 "/usr/include/stdio.h" 3 4
\r
401 extern char *tmpnam (char *__s) __attribute__ ((__nothrow__ )) ;
\r
407 extern char *tmpnam_r (char *__s) __attribute__ ((__nothrow__ )) ;
\r
408 # 227 "/usr/include/stdio.h" 3 4
\r
409 extern char *tempnam (const char *__dir, const char *__pfx)
\r
410 __attribute__ ((__nothrow__ )) __attribute__ ((__malloc__)) ;
\r
411 # 237 "/usr/include/stdio.h" 3 4
\r
412 extern int fclose (FILE *__stream);
\r
417 extern int fflush (FILE *__stream);
\r
418 # 252 "/usr/include/stdio.h" 3 4
\r
419 extern int fflush_unlocked (FILE *__stream);
\r
420 # 272 "/usr/include/stdio.h" 3 4
\r
421 extern FILE *fopen (const char *__restrict __filename,
\r
422 const char *__restrict __modes) ;
\r
427 extern FILE *freopen (const char *__restrict __filename,
\r
428 const char *__restrict __modes,
\r
429 FILE *__restrict __stream) ;
\r
430 # 306 "/usr/include/stdio.h" 3 4
\r
431 extern FILE *fdopen (int __fd, const char *__modes) __attribute__ ((__nothrow__ )) ;
\r
432 # 319 "/usr/include/stdio.h" 3 4
\r
433 extern FILE *fmemopen (void *__s, size_t __len, const char *__modes)
\r
434 __attribute__ ((__nothrow__ )) ;
\r
439 extern FILE *open_memstream (char **__bufloc, size_t *__sizeloc) __attribute__ ((__nothrow__ )) ;
\r
446 extern void setbuf (FILE *__restrict __stream, char *__restrict __buf) __attribute__ ((__nothrow__ ));
\r
450 extern int setvbuf (FILE *__restrict __stream, char *__restrict __buf,
\r
451 int __modes, size_t __n) __attribute__ ((__nothrow__ ));
\r
457 extern void setbuffer (FILE *__restrict __stream, char *__restrict __buf,
\r
458 size_t __size) __attribute__ ((__nothrow__ ));
\r
461 extern void setlinebuf (FILE *__stream) __attribute__ ((__nothrow__ ));
\r
462 # 356 "/usr/include/stdio.h" 3 4
\r
463 extern int fprintf (FILE *__restrict __stream,
\r
464 const char *__restrict __format, ...);
\r
469 extern int printf (const char *__restrict __format, ...);
\r
471 extern int sprintf (char *__restrict __s,
\r
472 const char *__restrict __format, ...) __attribute__ ((__nothrow__));
\r
478 extern int vfprintf (FILE *__restrict __s, const char *__restrict __format,
\r
479 __gnuc_va_list __arg);
\r
484 extern int vprintf (const char *__restrict __format, __gnuc_va_list __arg);
\r
486 extern int vsprintf (char *__restrict __s, const char *__restrict __format,
\r
487 __gnuc_va_list __arg) __attribute__ ((__nothrow__));
\r
493 extern int snprintf (char *__restrict __s, size_t __maxlen,
\r
494 const char *__restrict __format, ...)
\r
495 __attribute__ ((__nothrow__)) __attribute__ ((__format__ (__printf__, 3, 4)));
\r
497 extern int vsnprintf (char *__restrict __s, size_t __maxlen,
\r
498 const char *__restrict __format, __gnuc_va_list __arg)
\r
499 __attribute__ ((__nothrow__)) __attribute__ ((__format__ (__printf__, 3, 0)));
\r
500 # 412 "/usr/include/stdio.h" 3 4
\r
501 extern int vdprintf (int __fd, const char *__restrict __fmt,
\r
502 __gnuc_va_list __arg)
\r
503 __attribute__ ((__format__ (__printf__, 2, 0)));
\r
504 extern int dprintf (int __fd, const char *__restrict __fmt, ...)
\r
505 __attribute__ ((__format__ (__printf__, 2, 3)));
\r
506 # 425 "/usr/include/stdio.h" 3 4
\r
507 extern int fscanf (FILE *__restrict __stream,
\r
508 const char *__restrict __format, ...) ;
\r
513 extern int scanf (const char *__restrict __format, ...) ;
\r
515 extern int sscanf (const char *__restrict __s,
\r
516 const char *__restrict __format, ...) __attribute__ ((__nothrow__ ));
\r
517 # 443 "/usr/include/stdio.h" 3 4
\r
518 extern int fscanf (FILE *__restrict __stream, const char *__restrict __format, ...) __asm__ ("" "__isoc99_fscanf") ;
\r
521 extern int scanf (const char *__restrict __format, ...) __asm__ ("" "__isoc99_scanf") ;
\r
523 extern int sscanf (const char *__restrict __s, const char *__restrict __format, ...) __asm__ ("" "__isoc99_sscanf") __attribute__ ((__nothrow__ ));
\r
524 # 471 "/usr/include/stdio.h" 3 4
\r
525 extern int vfscanf (FILE *__restrict __s, const char *__restrict __format,
\r
526 __gnuc_va_list __arg)
\r
527 __attribute__ ((__format__ (__scanf__, 2, 0))) ;
\r
533 extern int vscanf (const char *__restrict __format, __gnuc_va_list __arg)
\r
534 __attribute__ ((__format__ (__scanf__, 1, 0))) ;
\r
537 extern int vsscanf (const char *__restrict __s,
\r
538 const char *__restrict __format, __gnuc_va_list __arg)
\r
539 __attribute__ ((__nothrow__ )) __attribute__ ((__format__ (__scanf__, 2, 0)));
\r
540 # 494 "/usr/include/stdio.h" 3 4
\r
541 extern int vfscanf (FILE *__restrict __s, const char *__restrict __format, __gnuc_va_list __arg) __asm__ ("" "__isoc99_vfscanf")
\r
545 __attribute__ ((__format__ (__scanf__, 2, 0))) ;
\r
546 extern int vscanf (const char *__restrict __format, __gnuc_va_list __arg) __asm__ ("" "__isoc99_vscanf")
\r
548 __attribute__ ((__format__ (__scanf__, 1, 0))) ;
\r
549 extern int vsscanf (const char *__restrict __s, const char *__restrict __format, __gnuc_va_list __arg) __asm__ ("" "__isoc99_vsscanf") __attribute__ ((__nothrow__ ))
\r
553 __attribute__ ((__format__ (__scanf__, 2, 0)));
\r
554 # 531 "/usr/include/stdio.h" 3 4
\r
555 extern int fgetc (FILE *__stream);
\r
556 extern int getc (FILE *__stream);
\r
562 extern int getchar (void);
\r
563 # 550 "/usr/include/stdio.h" 3 4
\r
564 extern int getc_unlocked (FILE *__stream);
\r
565 extern int getchar_unlocked (void);
\r
566 # 561 "/usr/include/stdio.h" 3 4
\r
567 extern int fgetc_unlocked (FILE *__stream);
\r
568 # 573 "/usr/include/stdio.h" 3 4
\r
569 extern int fputc (int __c, FILE *__stream);
\r
570 extern int putc (int __c, FILE *__stream);
\r
576 extern int putchar (int __c);
\r
577 # 594 "/usr/include/stdio.h" 3 4
\r
578 extern int fputc_unlocked (int __c, FILE *__stream);
\r
586 extern int putc_unlocked (int __c, FILE *__stream);
\r
587 extern int putchar_unlocked (int __c);
\r
594 extern int getw (FILE *__stream);
\r
597 extern int putw (int __w, FILE *__stream);
\r
598 # 622 "/usr/include/stdio.h" 3 4
\r
599 extern char *fgets (char *__restrict __s, int __n, FILE *__restrict __stream)
\r
601 # 638 "/usr/include/stdio.h" 3 4
\r
602 extern char *gets (char *__s) __attribute__ ((__deprecated__));
\r
603 # 665 "/usr/include/stdio.h" 3 4
\r
604 extern __ssize_t __getdelim (char **__restrict __lineptr,
\r
605 size_t *__restrict __n, int __delimiter,
\r
606 FILE *__restrict __stream) ;
\r
607 extern __ssize_t getdelim (char **__restrict __lineptr,
\r
608 size_t *__restrict __n, int __delimiter,
\r
609 FILE *__restrict __stream) ;
\r
617 extern __ssize_t getline (char **__restrict __lineptr,
\r
618 size_t *__restrict __n,
\r
619 FILE *__restrict __stream) ;
\r
620 # 689 "/usr/include/stdio.h" 3 4
\r
621 extern int fputs (const char *__restrict __s, FILE *__restrict __stream);
\r
627 extern int puts (const char *__s);
\r
634 extern int ungetc (int __c, FILE *__stream);
\r
641 extern size_t fread (void *__restrict __ptr, size_t __size,
\r
642 size_t __n, FILE *__restrict __stream) ;
\r
647 extern size_t fwrite (const void *__restrict __ptr, size_t __size,
\r
648 size_t __n, FILE *__restrict __s);
\r
649 # 737 "/usr/include/stdio.h" 3 4
\r
650 extern size_t fread_unlocked (void *__restrict __ptr, size_t __size,
\r
651 size_t __n, FILE *__restrict __stream) ;
\r
652 extern size_t fwrite_unlocked (const void *__restrict __ptr, size_t __size,
\r
653 size_t __n, FILE *__restrict __stream);
\r
654 # 749 "/usr/include/stdio.h" 3 4
\r
655 extern int fseek (FILE *__stream, long int __off, int __whence);
\r
660 extern long int ftell (FILE *__stream) ;
\r
665 extern void rewind (FILE *__stream);
\r
666 # 773 "/usr/include/stdio.h" 3 4
\r
667 extern int fseeko (FILE *__stream, __off_t __off, int __whence);
\r
672 extern __off_t ftello (FILE *__stream) ;
\r
673 # 798 "/usr/include/stdio.h" 3 4
\r
674 extern int fgetpos (FILE *__restrict __stream, fpos_t *__restrict __pos);
\r
679 extern int fsetpos (FILE *__stream, const fpos_t *__pos);
\r
680 # 826 "/usr/include/stdio.h" 3 4
\r
681 extern void clearerr (FILE *__stream) __attribute__ ((__nothrow__ ));
\r
683 extern int feof (FILE *__stream) __attribute__ ((__nothrow__ )) ;
\r
685 extern int ferror (FILE *__stream) __attribute__ ((__nothrow__ )) ;
\r
690 extern void clearerr_unlocked (FILE *__stream) __attribute__ ((__nothrow__ ));
\r
691 extern int feof_unlocked (FILE *__stream) __attribute__ ((__nothrow__ )) ;
\r
692 extern int ferror_unlocked (FILE *__stream) __attribute__ ((__nothrow__ )) ;
\r
693 # 846 "/usr/include/stdio.h" 3 4
\r
694 extern void perror (const char *__s);
\r
702 # 1 "/usr/include/x86_64-linux-gnu/bits/sys_errlist.h" 1 3 4
\r
703 # 26 "/usr/include/x86_64-linux-gnu/bits/sys_errlist.h" 3 4
\r
704 extern int sys_nerr;
\r
705 extern const char *const sys_errlist[];
\r
706 # 854 "/usr/include/stdio.h" 2 3 4
\r
711 extern int fileno (FILE *__stream) __attribute__ ((__nothrow__ )) ;
\r
716 extern int fileno_unlocked (FILE *__stream) __attribute__ ((__nothrow__ )) ;
\r
717 # 873 "/usr/include/stdio.h" 3 4
\r
718 extern FILE *popen (const char *__command, const char *__modes) ;
\r
724 extern int pclose (FILE *__stream);
\r
730 extern char *ctermid (char *__s) __attribute__ ((__nothrow__ ));
\r
731 # 913 "/usr/include/stdio.h" 3 4
\r
732 extern void flockfile (FILE *__stream) __attribute__ ((__nothrow__ ));
\r
736 extern int ftrylockfile (FILE *__stream) __attribute__ ((__nothrow__ )) ;
\r
739 extern void funlockfile (FILE *__stream) __attribute__ ((__nothrow__ ));
\r
740 # 23 "./../test/abts.h" 2
\r
741 # 1 "/usr/include/stdlib.h" 1 3 4
\r
742 # 32 "/usr/include/stdlib.h" 3 4
\r
743 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stddef.h" 1 3 4
\r
744 # 86 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stddef.h" 3 4
\r
745 typedef int wchar_t;
\r
746 # 33 "/usr/include/stdlib.h" 2 3 4
\r
755 # 1 "/usr/include/x86_64-linux-gnu/bits/waitflags.h" 1 3 4
\r
756 # 50 "/usr/include/x86_64-linux-gnu/bits/waitflags.h" 3 4
\r
763 # 42 "/usr/include/stdlib.h" 2 3 4
\r
764 # 1 "/usr/include/x86_64-linux-gnu/bits/waitstatus.h" 1 3 4
\r
765 # 64 "/usr/include/x86_64-linux-gnu/bits/waitstatus.h" 3 4
\r
766 # 1 "/usr/include/endian.h" 1 3 4
\r
767 # 36 "/usr/include/endian.h" 3 4
\r
768 # 1 "/usr/include/x86_64-linux-gnu/bits/endian.h" 1 3 4
\r
769 # 37 "/usr/include/endian.h" 2 3 4
\r
770 # 60 "/usr/include/endian.h" 3 4
\r
771 # 1 "/usr/include/x86_64-linux-gnu/bits/byteswap.h" 1 3 4
\r
772 # 28 "/usr/include/x86_64-linux-gnu/bits/byteswap.h" 3 4
\r
773 # 1 "/usr/include/x86_64-linux-gnu/bits/wordsize.h" 1 3 4
\r
774 # 29 "/usr/include/x86_64-linux-gnu/bits/byteswap.h" 2 3 4
\r
781 # 1 "/usr/include/x86_64-linux-gnu/bits/byteswap-16.h" 1 3 4
\r
782 # 36 "/usr/include/x86_64-linux-gnu/bits/byteswap.h" 2 3 4
\r
783 # 61 "/usr/include/endian.h" 2 3 4
\r
784 # 65 "/usr/include/x86_64-linux-gnu/bits/waitstatus.h" 2 3 4
\r
792 unsigned int __w_termsig:7;
\r
793 unsigned int __w_coredump:1;
\r
794 unsigned int __w_retcode:8;
\r
803 } __wait_terminated;
\r
807 unsigned int __w_stopval:8;
\r
808 unsigned int __w_stopsig:8;
\r
818 # 43 "/usr/include/stdlib.h" 2 3 4
\r
819 # 67 "/usr/include/stdlib.h" 3 4
\r
822 union wait *__uptr;
\r
824 } __WAIT_STATUS __attribute__ ((__transparent_union__));
\r
825 # 97 "/usr/include/stdlib.h" 3 4
\r
846 __extension__ typedef struct
\r
848 long long int quot;
\r
851 # 139 "/usr/include/stdlib.h" 3 4
\r
852 extern size_t __ctype_get_mb_cur_max (void) __attribute__ ((__nothrow__ )) ;
\r
857 extern double atof (const char *__nptr)
\r
858 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ;
\r
860 extern int atoi (const char *__nptr)
\r
861 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ;
\r
863 extern long int atol (const char *__nptr)
\r
864 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ;
\r
870 __extension__ extern long long int atoll (const char *__nptr)
\r
871 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ;
\r
877 extern double strtod (const char *__restrict __nptr,
\r
878 char **__restrict __endptr)
\r
879 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
885 extern float strtof (const char *__restrict __nptr,
\r
886 char **__restrict __endptr) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
888 extern long double strtold (const char *__restrict __nptr,
\r
889 char **__restrict __endptr)
\r
890 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
896 extern long int strtol (const char *__restrict __nptr,
\r
897 char **__restrict __endptr, int __base)
\r
898 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
900 extern unsigned long int strtoul (const char *__restrict __nptr,
\r
901 char **__restrict __endptr, int __base)
\r
902 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
908 extern long long int strtoq (const char *__restrict __nptr,
\r
909 char **__restrict __endptr, int __base)
\r
910 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
913 extern unsigned long long int strtouq (const char *__restrict __nptr,
\r
914 char **__restrict __endptr, int __base)
\r
915 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
922 extern long long int strtoll (const char *__restrict __nptr,
\r
923 char **__restrict __endptr, int __base)
\r
924 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
927 extern unsigned long long int strtoull (const char *__restrict __nptr,
\r
928 char **__restrict __endptr, int __base)
\r
929 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
930 # 305 "/usr/include/stdlib.h" 3 4
\r
931 extern char *l64a (long int __n) __attribute__ ((__nothrow__ )) ;
\r
934 extern long int a64l (const char *__s)
\r
935 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ;
\r
941 # 1 "/usr/include/x86_64-linux-gnu/sys/types.h" 1 3 4
\r
942 # 33 "/usr/include/x86_64-linux-gnu/sys/types.h" 3 4
\r
943 typedef __u_char u_char;
\r
944 typedef __u_short u_short;
\r
945 typedef __u_int u_int;
\r
946 typedef __u_long u_long;
\r
947 typedef __quad_t quad_t;
\r
948 typedef __u_quad_t u_quad_t;
\r
949 typedef __fsid_t fsid_t;
\r
954 typedef __loff_t loff_t;
\r
958 typedef __ino_t ino_t;
\r
959 # 60 "/usr/include/x86_64-linux-gnu/sys/types.h" 3 4
\r
960 typedef __dev_t dev_t;
\r
965 typedef __gid_t gid_t;
\r
970 typedef __mode_t mode_t;
\r
975 typedef __nlink_t nlink_t;
\r
980 typedef __uid_t uid_t;
\r
981 # 98 "/usr/include/x86_64-linux-gnu/sys/types.h" 3 4
\r
982 typedef __pid_t pid_t;
\r
988 typedef __id_t id_t;
\r
989 # 115 "/usr/include/x86_64-linux-gnu/sys/types.h" 3 4
\r
990 typedef __daddr_t daddr_t;
\r
991 typedef __caddr_t caddr_t;
\r
997 typedef __key_t key_t;
\r
998 # 132 "/usr/include/x86_64-linux-gnu/sys/types.h" 3 4
\r
999 # 1 "/usr/include/time.h" 1 3 4
\r
1000 # 59 "/usr/include/time.h" 3 4
\r
1001 typedef __clock_t clock_t;
\r
1002 # 75 "/usr/include/time.h" 3 4
\r
1003 typedef __time_t time_t;
\r
1004 # 91 "/usr/include/time.h" 3 4
\r
1005 typedef __clockid_t clockid_t;
\r
1006 # 103 "/usr/include/time.h" 3 4
\r
1007 typedef __timer_t timer_t;
\r
1008 # 133 "/usr/include/x86_64-linux-gnu/sys/types.h" 2 3 4
\r
1009 # 146 "/usr/include/x86_64-linux-gnu/sys/types.h" 3 4
\r
1010 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stddef.h" 1 3 4
\r
1011 # 147 "/usr/include/x86_64-linux-gnu/sys/types.h" 2 3 4
\r
1015 typedef unsigned long int ulong;
\r
1016 typedef unsigned short int ushort;
\r
1017 typedef unsigned int uint;
\r
1018 # 194 "/usr/include/x86_64-linux-gnu/sys/types.h" 3 4
\r
1019 typedef int int8_t __attribute__ ((__mode__ (__QI__)));
\r
1020 typedef int int16_t __attribute__ ((__mode__ (__HI__)));
\r
1021 typedef int int32_t __attribute__ ((__mode__ (__SI__)));
\r
1022 typedef int int64_t __attribute__ ((__mode__ (__DI__)));
\r
1025 typedef unsigned int u_int8_t __attribute__ ((__mode__ (__QI__)));
\r
1026 typedef unsigned int u_int16_t __attribute__ ((__mode__ (__HI__)));
\r
1027 typedef unsigned int u_int32_t __attribute__ ((__mode__ (__SI__)));
\r
1028 typedef unsigned int u_int64_t __attribute__ ((__mode__ (__DI__)));
\r
1030 typedef int register_t __attribute__ ((__mode__ (__word__)));
\r
1031 # 219 "/usr/include/x86_64-linux-gnu/sys/types.h" 3 4
\r
1032 # 1 "/usr/include/x86_64-linux-gnu/sys/select.h" 1 3 4
\r
1033 # 30 "/usr/include/x86_64-linux-gnu/sys/select.h" 3 4
\r
1034 # 1 "/usr/include/x86_64-linux-gnu/bits/select.h" 1 3 4
\r
1035 # 22 "/usr/include/x86_64-linux-gnu/bits/select.h" 3 4
\r
1036 # 1 "/usr/include/x86_64-linux-gnu/bits/wordsize.h" 1 3 4
\r
1037 # 23 "/usr/include/x86_64-linux-gnu/bits/select.h" 2 3 4
\r
1038 # 31 "/usr/include/x86_64-linux-gnu/sys/select.h" 2 3 4
\r
1041 # 1 "/usr/include/x86_64-linux-gnu/bits/sigset.h" 1 3 4
\r
1042 # 22 "/usr/include/x86_64-linux-gnu/bits/sigset.h" 3 4
\r
1043 typedef int __sig_atomic_t;
\r
1050 unsigned long int __val[(1024 / (8 * sizeof (unsigned long int)))];
\r
1052 # 34 "/usr/include/x86_64-linux-gnu/sys/select.h" 2 3 4
\r
1056 typedef __sigset_t sigset_t;
\r
1063 # 1 "/usr/include/time.h" 1 3 4
\r
1064 # 120 "/usr/include/time.h" 3 4
\r
1068 __syscall_slong_t tv_nsec;
\r
1070 # 44 "/usr/include/x86_64-linux-gnu/sys/select.h" 2 3 4
\r
1072 # 1 "/usr/include/x86_64-linux-gnu/bits/time.h" 1 3 4
\r
1073 # 30 "/usr/include/x86_64-linux-gnu/bits/time.h" 3 4
\r
1077 __suseconds_t tv_usec;
\r
1079 # 46 "/usr/include/x86_64-linux-gnu/sys/select.h" 2 3 4
\r
1082 typedef __suseconds_t suseconds_t;
\r
1088 typedef long int __fd_mask;
\r
1089 # 64 "/usr/include/x86_64-linux-gnu/sys/select.h" 3 4
\r
1098 __fd_mask __fds_bits[1024 / (8 * (int) sizeof (__fd_mask))];
\r
1108 typedef __fd_mask fd_mask;
\r
1109 # 106 "/usr/include/x86_64-linux-gnu/sys/select.h" 3 4
\r
1110 extern int select (int __nfds, fd_set *__restrict __readfds,
\r
1111 fd_set *__restrict __writefds,
\r
1112 fd_set *__restrict __exceptfds,
\r
1113 struct timeval *__restrict __timeout);
\r
1114 # 118 "/usr/include/x86_64-linux-gnu/sys/select.h" 3 4
\r
1115 extern int pselect (int __nfds, fd_set *__restrict __readfds,
\r
1116 fd_set *__restrict __writefds,
\r
1117 fd_set *__restrict __exceptfds,
\r
1118 const struct timespec *__restrict __timeout,
\r
1119 const __sigset_t *__restrict __sigmask);
\r
1120 # 220 "/usr/include/x86_64-linux-gnu/sys/types.h" 2 3 4
\r
1123 # 1 "/usr/include/x86_64-linux-gnu/sys/sysmacros.h" 1 3 4
\r
1124 # 26 "/usr/include/x86_64-linux-gnu/sys/sysmacros.h" 3 4
\r
1126 extern unsigned int gnu_dev_major (unsigned long long int __dev)
\r
1127 __attribute__ ((__nothrow__ )) __attribute__ ((__const__));
\r
1129 extern unsigned int gnu_dev_minor (unsigned long long int __dev)
\r
1130 __attribute__ ((__nothrow__ )) __attribute__ ((__const__));
\r
1132 extern unsigned long long int gnu_dev_makedev (unsigned int __major,
\r
1133 unsigned int __minor)
\r
1134 __attribute__ ((__nothrow__ )) __attribute__ ((__const__));
\r
1135 # 223 "/usr/include/x86_64-linux-gnu/sys/types.h" 2 3 4
\r
1141 typedef __blksize_t blksize_t;
\r
1148 typedef __blkcnt_t blkcnt_t;
\r
1152 typedef __fsblkcnt_t fsblkcnt_t;
\r
1156 typedef __fsfilcnt_t fsfilcnt_t;
\r
1157 # 270 "/usr/include/x86_64-linux-gnu/sys/types.h" 3 4
\r
1158 # 1 "/usr/include/x86_64-linux-gnu/bits/pthreadtypes.h" 1 3 4
\r
1159 # 21 "/usr/include/x86_64-linux-gnu/bits/pthreadtypes.h" 3 4
\r
1160 # 1 "/usr/include/x86_64-linux-gnu/bits/wordsize.h" 1 3 4
\r
1161 # 22 "/usr/include/x86_64-linux-gnu/bits/pthreadtypes.h" 2 3 4
\r
1162 # 60 "/usr/include/x86_64-linux-gnu/bits/pthreadtypes.h" 3 4
\r
1163 typedef unsigned long int pthread_t;
\r
1166 union pthread_attr_t
\r
1172 typedef union pthread_attr_t pthread_attr_t;
\r
1178 typedef struct __pthread_internal_list
\r
1180 struct __pthread_internal_list *__prev;
\r
1181 struct __pthread_internal_list *__next;
\r
1182 } __pthread_list_t;
\r
1183 # 90 "/usr/include/x86_64-linux-gnu/bits/pthreadtypes.h" 3 4
\r
1186 struct __pthread_mutex_s
\r
1189 unsigned int __count;
\r
1192 unsigned int __nusers;
\r
1200 __pthread_list_t __list;
\r
1201 # 124 "/usr/include/x86_64-linux-gnu/bits/pthreadtypes.h" 3 4
\r
1205 } pthread_mutex_t;
\r
1211 } pthread_mutexattr_t;
\r
1221 unsigned int __futex;
\r
1222 __extension__ unsigned long long int __total_seq;
\r
1223 __extension__ unsigned long long int __wakeup_seq;
\r
1224 __extension__ unsigned long long int __woken_seq;
\r
1226 unsigned int __nwaiters;
\r
1227 unsigned int __broadcast_seq;
\r
1230 __extension__ long long int __align;
\r
1237 } pthread_condattr_t;
\r
1241 typedef unsigned int pthread_key_t;
\r
1245 typedef int pthread_once_t;
\r
1257 unsigned int __nr_readers;
\r
1258 unsigned int __readers_wakeup;
\r
1259 unsigned int __writer_wakeup;
\r
1260 unsigned int __nr_readers_queued;
\r
1261 unsigned int __nr_writers_queued;
\r
1264 unsigned long int __pad1;
\r
1265 unsigned long int __pad2;
\r
1268 unsigned int __flags;
\r
1271 # 211 "/usr/include/x86_64-linux-gnu/bits/pthreadtypes.h" 3 4
\r
1274 } pthread_rwlock_t;
\r
1280 } pthread_rwlockattr_t;
\r
1286 typedef volatile int pthread_spinlock_t;
\r
1295 } pthread_barrier_t;
\r
1301 } pthread_barrierattr_t;
\r
1302 # 271 "/usr/include/x86_64-linux-gnu/sys/types.h" 2 3 4
\r
1303 # 315 "/usr/include/stdlib.h" 2 3 4
\r
1310 extern long int random (void) __attribute__ ((__nothrow__ ));
\r
1313 extern void srandom (unsigned int __seed) __attribute__ ((__nothrow__ ));
\r
1319 extern char *initstate (unsigned int __seed, char *__statebuf,
\r
1320 size_t __statelen) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2)));
\r
1324 extern char *setstate (char *__statebuf) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
1332 struct random_data
\r
1343 extern int random_r (struct random_data *__restrict __buf,
\r
1344 int32_t *__restrict __result) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1346 extern int srandom_r (unsigned int __seed, struct random_data *__buf)
\r
1347 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2)));
\r
1349 extern int initstate_r (unsigned int __seed, char *__restrict __statebuf,
\r
1350 size_t __statelen,
\r
1351 struct random_data *__restrict __buf)
\r
1352 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2, 4)));
\r
1354 extern int setstate_r (char *__restrict __statebuf,
\r
1355 struct random_data *__restrict __buf)
\r
1356 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1363 extern int rand (void) __attribute__ ((__nothrow__ ));
\r
1365 extern void srand (unsigned int __seed) __attribute__ ((__nothrow__ ));
\r
1370 extern int rand_r (unsigned int *__seed) __attribute__ ((__nothrow__ ));
\r
1378 extern double drand48 (void) __attribute__ ((__nothrow__ ));
\r
1379 extern double erand48 (unsigned short int __xsubi[3]) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
1382 extern long int lrand48 (void) __attribute__ ((__nothrow__ ));
\r
1383 extern long int nrand48 (unsigned short int __xsubi[3])
\r
1384 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
1387 extern long int mrand48 (void) __attribute__ ((__nothrow__ ));
\r
1388 extern long int jrand48 (unsigned short int __xsubi[3])
\r
1389 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
1392 extern void srand48 (long int __seedval) __attribute__ ((__nothrow__ ));
\r
1393 extern unsigned short int *seed48 (unsigned short int __seed16v[3])
\r
1394 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
1395 extern void lcong48 (unsigned short int __param[7]) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
1401 struct drand48_data
\r
1403 unsigned short int __x[3];
\r
1404 unsigned short int __old_x[3];
\r
1405 unsigned short int __c;
\r
1406 unsigned short int __init;
\r
1407 __extension__ unsigned long long int __a;
\r
1412 extern int drand48_r (struct drand48_data *__restrict __buffer,
\r
1413 double *__restrict __result) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1414 extern int erand48_r (unsigned short int __xsubi[3],
\r
1415 struct drand48_data *__restrict __buffer,
\r
1416 double *__restrict __result) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1419 extern int lrand48_r (struct drand48_data *__restrict __buffer,
\r
1420 long int *__restrict __result)
\r
1421 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1422 extern int nrand48_r (unsigned short int __xsubi[3],
\r
1423 struct drand48_data *__restrict __buffer,
\r
1424 long int *__restrict __result)
\r
1425 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1428 extern int mrand48_r (struct drand48_data *__restrict __buffer,
\r
1429 long int *__restrict __result)
\r
1430 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1431 extern int jrand48_r (unsigned short int __xsubi[3],
\r
1432 struct drand48_data *__restrict __buffer,
\r
1433 long int *__restrict __result)
\r
1434 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1437 extern int srand48_r (long int __seedval, struct drand48_data *__buffer)
\r
1438 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2)));
\r
1440 extern int seed48_r (unsigned short int __seed16v[3],
\r
1441 struct drand48_data *__buffer) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1443 extern int lcong48_r (unsigned short int __param[7],
\r
1444 struct drand48_data *__buffer)
\r
1445 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1446 # 466 "/usr/include/stdlib.h" 3 4
\r
1447 extern void *malloc (size_t __size) __attribute__ ((__nothrow__ )) __attribute__ ((__malloc__)) ;
\r
1449 extern void *calloc (size_t __nmemb, size_t __size)
\r
1450 __attribute__ ((__nothrow__ )) __attribute__ ((__malloc__)) ;
\r
1451 # 480 "/usr/include/stdlib.h" 3 4
\r
1452 extern void *realloc (void *__ptr, size_t __size)
\r
1453 __attribute__ ((__nothrow__ )) __attribute__ ((__warn_unused_result__));
\r
1455 extern void free (void *__ptr) __attribute__ ((__nothrow__ ));
\r
1460 extern void cfree (void *__ptr) __attribute__ ((__nothrow__ ));
\r
1465 # 1 "/usr/include/alloca.h" 1 3 4
\r
1466 # 24 "/usr/include/alloca.h" 3 4
\r
1467 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stddef.h" 1 3 4
\r
1468 # 25 "/usr/include/alloca.h" 2 3 4
\r
1476 extern void *alloca (size_t __size) __attribute__ ((__nothrow__ ));
\r
1477 # 493 "/usr/include/stdlib.h" 2 3 4
\r
1483 extern void *valloc (size_t __size) __attribute__ ((__nothrow__ )) __attribute__ ((__malloc__)) ;
\r
1488 extern int posix_memalign (void **__memptr, size_t __alignment, size_t __size)
\r
1489 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1))) ;
\r
1490 # 515 "/usr/include/stdlib.h" 3 4
\r
1491 extern void abort (void) __attribute__ ((__nothrow__ )) __attribute__ ((__noreturn__));
\r
1495 extern int atexit (void (*__func) (void)) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
1496 # 535 "/usr/include/stdlib.h" 3 4
\r
1497 extern int on_exit (void (*__func) (int __status, void *__arg), void *__arg)
\r
1498 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
1505 extern void exit (int __status) __attribute__ ((__nothrow__ )) __attribute__ ((__noreturn__));
\r
1506 # 557 "/usr/include/stdlib.h" 3 4
\r
1507 extern void _Exit (int __status) __attribute__ ((__nothrow__ )) __attribute__ ((__noreturn__));
\r
1514 extern char *getenv (const char *__name) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1))) ;
\r
1515 # 578 "/usr/include/stdlib.h" 3 4
\r
1516 extern int putenv (char *__string) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
1522 extern int setenv (const char *__name, const char *__value, int __replace)
\r
1523 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2)));
\r
1526 extern int unsetenv (const char *__name) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
1533 extern int clearenv (void) __attribute__ ((__nothrow__ ));
\r
1534 # 606 "/usr/include/stdlib.h" 3 4
\r
1535 extern char *mktemp (char *__template) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
1536 # 620 "/usr/include/stdlib.h" 3 4
\r
1537 extern int mkstemp (char *__template) __attribute__ ((__nonnull__ (1))) ;
\r
1538 # 642 "/usr/include/stdlib.h" 3 4
\r
1539 extern int mkstemps (char *__template, int __suffixlen) __attribute__ ((__nonnull__ (1))) ;
\r
1540 # 663 "/usr/include/stdlib.h" 3 4
\r
1541 extern char *mkdtemp (char *__template) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1))) ;
\r
1542 # 717 "/usr/include/stdlib.h" 3 4
\r
1543 extern int system (const char *__command) ;
\r
1544 # 734 "/usr/include/stdlib.h" 3 4
\r
1545 extern char *realpath (const char *__restrict __name,
\r
1546 char *__restrict __resolved) __attribute__ ((__nothrow__ )) ;
\r
1553 typedef int (*__compar_fn_t) (const void *, const void *);
\r
1554 # 755 "/usr/include/stdlib.h" 3 4
\r
1555 extern void *bsearch (const void *__key, const void *__base,
\r
1556 size_t __nmemb, size_t __size, __compar_fn_t __compar)
\r
1557 __attribute__ ((__nonnull__ (1, 2, 5))) ;
\r
1565 extern void qsort (void *__base, size_t __nmemb, size_t __size,
\r
1566 __compar_fn_t __compar) __attribute__ ((__nonnull__ (1, 4)));
\r
1567 # 775 "/usr/include/stdlib.h" 3 4
\r
1568 extern int abs (int __x) __attribute__ ((__nothrow__ )) __attribute__ ((__const__)) ;
\r
1569 extern long int labs (long int __x) __attribute__ ((__nothrow__ )) __attribute__ ((__const__)) ;
\r
1573 __extension__ extern long long int llabs (long long int __x)
\r
1574 __attribute__ ((__nothrow__ )) __attribute__ ((__const__)) ;
\r
1582 extern div_t div (int __numer, int __denom)
\r
1583 __attribute__ ((__nothrow__ )) __attribute__ ((__const__)) ;
\r
1584 extern ldiv_t ldiv (long int __numer, long int __denom)
\r
1585 __attribute__ ((__nothrow__ )) __attribute__ ((__const__)) ;
\r
1590 __extension__ extern lldiv_t lldiv (long long int __numer,
\r
1591 long long int __denom)
\r
1592 __attribute__ ((__nothrow__ )) __attribute__ ((__const__)) ;
\r
1593 # 812 "/usr/include/stdlib.h" 3 4
\r
1594 extern char *ecvt (double __value, int __ndigit, int *__restrict __decpt,
\r
1595 int *__restrict __sign) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (3, 4))) ;
\r
1600 extern char *fcvt (double __value, int __ndigit, int *__restrict __decpt,
\r
1601 int *__restrict __sign) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (3, 4))) ;
\r
1606 extern char *gcvt (double __value, int __ndigit, char *__buf)
\r
1607 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (3))) ;
\r
1612 extern char *qecvt (long double __value, int __ndigit,
\r
1613 int *__restrict __decpt, int *__restrict __sign)
\r
1614 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (3, 4))) ;
\r
1615 extern char *qfcvt (long double __value, int __ndigit,
\r
1616 int *__restrict __decpt, int *__restrict __sign)
\r
1617 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (3, 4))) ;
\r
1618 extern char *qgcvt (long double __value, int __ndigit, char *__buf)
\r
1619 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (3))) ;
\r
1624 extern int ecvt_r (double __value, int __ndigit, int *__restrict __decpt,
\r
1625 int *__restrict __sign, char *__restrict __buf,
\r
1626 size_t __len) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (3, 4, 5)));
\r
1627 extern int fcvt_r (double __value, int __ndigit, int *__restrict __decpt,
\r
1628 int *__restrict __sign, char *__restrict __buf,
\r
1629 size_t __len) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (3, 4, 5)));
\r
1631 extern int qecvt_r (long double __value, int __ndigit,
\r
1632 int *__restrict __decpt, int *__restrict __sign,
\r
1633 char *__restrict __buf, size_t __len)
\r
1634 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (3, 4, 5)));
\r
1635 extern int qfcvt_r (long double __value, int __ndigit,
\r
1636 int *__restrict __decpt, int *__restrict __sign,
\r
1637 char *__restrict __buf, size_t __len)
\r
1638 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (3, 4, 5)));
\r
1645 extern int mblen (const char *__s, size_t __n) __attribute__ ((__nothrow__ ));
\r
1648 extern int mbtowc (wchar_t *__restrict __pwc,
\r
1649 const char *__restrict __s, size_t __n) __attribute__ ((__nothrow__ ));
\r
1652 extern int wctomb (char *__s, wchar_t __wchar) __attribute__ ((__nothrow__ ));
\r
1656 extern size_t mbstowcs (wchar_t *__restrict __pwcs,
\r
1657 const char *__restrict __s, size_t __n) __attribute__ ((__nothrow__ ));
\r
1659 extern size_t wcstombs (char *__restrict __s,
\r
1660 const wchar_t *__restrict __pwcs, size_t __n)
\r
1661 __attribute__ ((__nothrow__ ));
\r
1662 # 888 "/usr/include/stdlib.h" 3 4
\r
1663 extern int rpmatch (const char *__response) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1))) ;
\r
1664 # 899 "/usr/include/stdlib.h" 3 4
\r
1665 extern int getsubopt (char **__restrict __optionp,
\r
1666 char *const *__restrict __tokens,
\r
1667 char **__restrict __valuep)
\r
1668 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2, 3))) ;
\r
1669 # 951 "/usr/include/stdlib.h" 3 4
\r
1670 extern int getloadavg (double __loadavg[], int __nelem)
\r
1671 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
1675 # 1 "/usr/include/x86_64-linux-gnu/bits/stdlib-float.h" 1 3 4
\r
1676 # 956 "/usr/include/stdlib.h" 2 3 4
\r
1677 # 24 "./../test/abts.h" 2
\r
1678 # 1 "/usr/include/string.h" 1 3 4
\r
1679 # 32 "/usr/include/string.h" 3 4
\r
1680 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stddef.h" 1 3 4
\r
1681 # 33 "/usr/include/string.h" 2 3 4
\r
1682 # 46 "/usr/include/string.h" 3 4
\r
1683 extern void *memcpy (void *__restrict __dest, const void *__restrict __src,
\r
1684 size_t __n) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1687 extern void *memmove (void *__dest, const void *__src, size_t __n)
\r
1688 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1695 extern void *memccpy (void *__restrict __dest, const void *__restrict __src,
\r
1696 int __c, size_t __n)
\r
1697 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1703 extern void *memset (void *__s, int __c, size_t __n) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
1706 extern int memcmp (const void *__s1, const void *__s2, size_t __n)
\r
1707 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2)));
\r
1708 # 96 "/usr/include/string.h" 3 4
\r
1709 extern void *memchr (const void *__s, int __c, size_t __n)
\r
1710 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1)));
\r
1711 # 129 "/usr/include/string.h" 3 4
\r
1712 extern char *strcpy (char *__restrict __dest, const char *__restrict __src)
\r
1713 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1715 extern char *strncpy (char *__restrict __dest,
\r
1716 const char *__restrict __src, size_t __n)
\r
1717 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1720 extern char *strcat (char *__restrict __dest, const char *__restrict __src)
\r
1721 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1723 extern char *strncat (char *__restrict __dest, const char *__restrict __src,
\r
1724 size_t __n) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1727 extern int strcmp (const char *__s1, const char *__s2)
\r
1728 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2)));
\r
1730 extern int strncmp (const char *__s1, const char *__s2, size_t __n)
\r
1731 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2)));
\r
1734 extern int strcoll (const char *__s1, const char *__s2)
\r
1735 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2)));
\r
1737 extern size_t strxfrm (char *__restrict __dest,
\r
1738 const char *__restrict __src, size_t __n)
\r
1739 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2)));
\r
1747 # 1 "/usr/include/xlocale.h" 1 3 4
\r
1748 # 27 "/usr/include/xlocale.h" 3 4
\r
1749 typedef struct __locale_struct
\r
1752 struct __locale_data *__locales[13];
\r
1755 const unsigned short int *__ctype_b;
\r
1756 const int *__ctype_tolower;
\r
1757 const int *__ctype_toupper;
\r
1760 const char *__names[13];
\r
1764 typedef __locale_t locale_t;
\r
1765 # 164 "/usr/include/string.h" 2 3 4
\r
1768 extern int strcoll_l (const char *__s1, const char *__s2, __locale_t __l)
\r
1769 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2, 3)));
\r
1771 extern size_t strxfrm_l (char *__dest, const char *__src, size_t __n,
\r
1772 __locale_t __l) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2, 4)));
\r
1778 extern char *strdup (const char *__s)
\r
1779 __attribute__ ((__nothrow__ )) __attribute__ ((__malloc__)) __attribute__ ((__nonnull__ (1)));
\r
1786 extern char *strndup (const char *__string, size_t __n)
\r
1787 __attribute__ ((__nothrow__ )) __attribute__ ((__malloc__)) __attribute__ ((__nonnull__ (1)));
\r
1788 # 236 "/usr/include/string.h" 3 4
\r
1789 extern char *strchr (const char *__s, int __c)
\r
1790 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1)));
\r
1791 # 263 "/usr/include/string.h" 3 4
\r
1792 extern char *strrchr (const char *__s, int __c)
\r
1793 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1)));
\r
1794 # 285 "/usr/include/string.h" 3 4
\r
1795 extern size_t strcspn (const char *__s, const char *__reject)
\r
1796 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2)));
\r
1799 extern size_t strspn (const char *__s, const char *__accept)
\r
1800 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2)));
\r
1801 # 315 "/usr/include/string.h" 3 4
\r
1802 extern char *strpbrk (const char *__s, const char *__accept)
\r
1803 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2)));
\r
1804 # 342 "/usr/include/string.h" 3 4
\r
1805 extern char *strstr (const char *__haystack, const char *__needle)
\r
1806 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2)));
\r
1811 extern char *strtok (char *__restrict __s, const char *__restrict __delim)
\r
1812 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2)));
\r
1817 extern char *__strtok_r (char *__restrict __s,
\r
1818 const char *__restrict __delim,
\r
1819 char **__restrict __save_ptr)
\r
1820 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2, 3)));
\r
1822 extern char *strtok_r (char *__restrict __s, const char *__restrict __delim,
\r
1823 char **__restrict __save_ptr)
\r
1824 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2, 3)));
\r
1825 # 399 "/usr/include/string.h" 3 4
\r
1826 extern size_t strlen (const char *__s)
\r
1827 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1)));
\r
1833 extern size_t strnlen (const char *__string, size_t __maxlen)
\r
1834 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1)));
\r
1840 extern char *strerror (int __errnum) __attribute__ ((__nothrow__ ));
\r
1841 # 427 "/usr/include/string.h" 3 4
\r
1842 extern int strerror_r (int __errnum, char *__buf, size_t __buflen) __asm__ ("" "__xpg_strerror_r") __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2)));
\r
1843 # 445 "/usr/include/string.h" 3 4
\r
1844 extern char *strerror_l (int __errnum, __locale_t __l) __attribute__ ((__nothrow__ ));
\r
1850 extern void __bzero (void *__s, size_t __n) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
1854 extern void bcopy (const void *__src, void *__dest, size_t __n)
\r
1855 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1858 extern void bzero (void *__s, size_t __n) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
1861 extern int bcmp (const void *__s1, const void *__s2, size_t __n)
\r
1862 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2)));
\r
1863 # 489 "/usr/include/string.h" 3 4
\r
1864 extern char *index (const char *__s, int __c)
\r
1865 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1)));
\r
1866 # 517 "/usr/include/string.h" 3 4
\r
1867 extern char *rindex (const char *__s, int __c)
\r
1868 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1)));
\r
1873 extern int ffs (int __i) __attribute__ ((__nothrow__ )) __attribute__ ((__const__));
\r
1874 # 534 "/usr/include/string.h" 3 4
\r
1875 extern int strcasecmp (const char *__s1, const char *__s2)
\r
1876 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2)));
\r
1879 extern int strncasecmp (const char *__s1, const char *__s2, size_t __n)
\r
1880 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2)));
\r
1881 # 557 "/usr/include/string.h" 3 4
\r
1882 extern char *strsep (char **__restrict __stringp,
\r
1883 const char *__restrict __delim)
\r
1884 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1889 extern char *strsignal (int __sig) __attribute__ ((__nothrow__ ));
\r
1892 extern char *__stpcpy (char *__restrict __dest, const char *__restrict __src)
\r
1893 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1894 extern char *stpcpy (char *__restrict __dest, const char *__restrict __src)
\r
1895 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1899 extern char *__stpncpy (char *__restrict __dest,
\r
1900 const char *__restrict __src, size_t __n)
\r
1901 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1902 extern char *stpncpy (char *__restrict __dest,
\r
1903 const char *__restrict __src, size_t __n)
\r
1904 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
1905 # 25 "./../test/abts.h" 2
\r
1909 # 1 "/usr/include/unistd.h" 1 3 4
\r
1910 # 202 "/usr/include/unistd.h" 3 4
\r
1911 # 1 "/usr/include/x86_64-linux-gnu/bits/posix_opt.h" 1 3 4
\r
1912 # 203 "/usr/include/unistd.h" 2 3 4
\r
1916 # 1 "/usr/include/x86_64-linux-gnu/bits/environments.h" 1 3 4
\r
1917 # 22 "/usr/include/x86_64-linux-gnu/bits/environments.h" 3 4
\r
1918 # 1 "/usr/include/x86_64-linux-gnu/bits/wordsize.h" 1 3 4
\r
1919 # 23 "/usr/include/x86_64-linux-gnu/bits/environments.h" 2 3 4
\r
1920 # 207 "/usr/include/unistd.h" 2 3 4
\r
1921 # 226 "/usr/include/unistd.h" 3 4
\r
1922 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stddef.h" 1 3 4
\r
1923 # 227 "/usr/include/unistd.h" 2 3 4
\r
1924 # 255 "/usr/include/unistd.h" 3 4
\r
1925 typedef __useconds_t useconds_t;
\r
1926 # 267 "/usr/include/unistd.h" 3 4
\r
1927 typedef __intptr_t intptr_t;
\r
1934 typedef __socklen_t socklen_t;
\r
1935 # 287 "/usr/include/unistd.h" 3 4
\r
1936 extern int access (const char *__name, int __type) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
1937 # 304 "/usr/include/unistd.h" 3 4
\r
1938 extern int faccessat (int __fd, const char *__file, int __type, int __flag)
\r
1939 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2))) ;
\r
1940 # 334 "/usr/include/unistd.h" 3 4
\r
1941 extern __off_t lseek (int __fd, __off_t __offset, int __whence) __attribute__ ((__nothrow__ ));
\r
1942 # 353 "/usr/include/unistd.h" 3 4
\r
1943 extern int close (int __fd);
\r
1950 extern ssize_t read (int __fd, void *__buf, size_t __nbytes) ;
\r
1956 extern ssize_t write (int __fd, const void *__buf, size_t __n) ;
\r
1957 # 376 "/usr/include/unistd.h" 3 4
\r
1958 extern ssize_t pread (int __fd, void *__buf, size_t __nbytes,
\r
1959 __off_t __offset) ;
\r
1966 extern ssize_t pwrite (int __fd, const void *__buf, size_t __n,
\r
1967 __off_t __offset) ;
\r
1968 # 417 "/usr/include/unistd.h" 3 4
\r
1969 extern int pipe (int __pipedes[2]) __attribute__ ((__nothrow__ )) ;
\r
1970 # 432 "/usr/include/unistd.h" 3 4
\r
1971 extern unsigned int alarm (unsigned int __seconds) __attribute__ ((__nothrow__ ));
\r
1972 # 444 "/usr/include/unistd.h" 3 4
\r
1973 extern unsigned int sleep (unsigned int __seconds);
\r
1981 extern __useconds_t ualarm (__useconds_t __value, __useconds_t __interval)
\r
1982 __attribute__ ((__nothrow__ ));
\r
1989 extern int usleep (__useconds_t __useconds);
\r
1990 # 469 "/usr/include/unistd.h" 3 4
\r
1991 extern int pause (void);
\r
1995 extern int chown (const char *__file, __uid_t __owner, __gid_t __group)
\r
1996 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1))) ;
\r
2000 extern int fchown (int __fd, __uid_t __owner, __gid_t __group) __attribute__ ((__nothrow__ )) ;
\r
2005 extern int lchown (const char *__file, __uid_t __owner, __gid_t __group)
\r
2006 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1))) ;
\r
2013 extern int fchownat (int __fd, const char *__file, __uid_t __owner,
\r
2014 __gid_t __group, int __flag)
\r
2015 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2))) ;
\r
2019 extern int chdir (const char *__path) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1))) ;
\r
2023 extern int fchdir (int __fd) __attribute__ ((__nothrow__ )) ;
\r
2024 # 511 "/usr/include/unistd.h" 3 4
\r
2025 extern char *getcwd (char *__buf, size_t __size) __attribute__ ((__nothrow__ )) ;
\r
2026 # 525 "/usr/include/unistd.h" 3 4
\r
2027 extern char *getwd (char *__buf)
\r
2028 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1))) __attribute__ ((__deprecated__)) ;
\r
2033 extern int dup (int __fd) __attribute__ ((__nothrow__ )) ;
\r
2036 extern int dup2 (int __fd, int __fd2) __attribute__ ((__nothrow__ ));
\r
2037 # 543 "/usr/include/unistd.h" 3 4
\r
2038 extern char **__environ;
\r
2046 extern int execve (const char *__path, char *const __argv[],
\r
2047 char *const __envp[]) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
2052 extern int fexecve (int __fd, char *const __argv[], char *const __envp[])
\r
2053 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2)));
\r
2058 extern int execv (const char *__path, char *const __argv[])
\r
2059 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
2063 extern int execle (const char *__path, const char *__arg, ...)
\r
2064 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
2068 extern int execl (const char *__path, const char *__arg, ...)
\r
2069 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
2073 extern int execvp (const char *__file, char *const __argv[])
\r
2074 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
2079 extern int execlp (const char *__file, const char *__arg, ...)
\r
2080 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
2081 # 598 "/usr/include/unistd.h" 3 4
\r
2082 extern int nice (int __inc) __attribute__ ((__nothrow__ )) ;
\r
2087 extern void _exit (int __status) __attribute__ ((__noreturn__));
\r
2094 # 1 "/usr/include/x86_64-linux-gnu/bits/confname.h" 1 3 4
\r
2095 # 24 "/usr/include/x86_64-linux-gnu/bits/confname.h" 3 4
\r
2110 _PC_CHOWN_RESTRICTED,
\r
2126 _PC_REC_INCR_XFER_SIZE,
\r
2128 _PC_REC_MAX_XFER_SIZE,
\r
2130 _PC_REC_MIN_XFER_SIZE,
\r
2132 _PC_REC_XFER_ALIGN,
\r
2134 _PC_ALLOC_SIZE_MIN,
\r
2163 _SC_REALTIME_SIGNALS,
\r
2165 _SC_PRIORITY_SCHEDULING,
\r
2169 _SC_ASYNCHRONOUS_IO,
\r
2171 _SC_PRIORITIZED_IO,
\r
2173 _SC_SYNCHRONIZED_IO,
\r
2181 _SC_MEMLOCK_RANGE,
\r
2183 _SC_MEMORY_PROTECTION,
\r
2185 _SC_MESSAGE_PASSING,
\r
2189 _SC_SHARED_MEMORY_OBJECTS,
\r
2191 _SC_AIO_LISTIO_MAX,
\r
2195 _SC_AIO_PRIO_DELTA_MAX,
\r
2197 _SC_DELAYTIMER_MAX,
\r
2210 _SC_SEM_NSEMS_MAX,
\r
2212 _SC_SEM_VALUE_MAX,
\r
2227 _SC_BC_STRING_MAX,
\r
2229 _SC_COLL_WEIGHTS_MAX,
\r
2231 _SC_EQUIV_CLASS_MAX,
\r
2233 _SC_EXPR_NEST_MAX,
\r
2239 _SC_CHARCLASS_NAME_MAX,
\r
2273 _SC_IOV_MAX = _SC_UIO_MAXIOV,
\r
2275 _SC_PII_INTERNET_STREAM,
\r
2277 _SC_PII_INTERNET_DGRAM,
\r
2291 _SC_THREAD_SAFE_FUNCTIONS,
\r
2293 _SC_GETGR_R_SIZE_MAX,
\r
2295 _SC_GETPW_R_SIZE_MAX,
\r
2297 _SC_LOGIN_NAME_MAX,
\r
2301 _SC_THREAD_DESTRUCTOR_ITERATIONS,
\r
2303 _SC_THREAD_KEYS_MAX,
\r
2305 _SC_THREAD_STACK_MIN,
\r
2307 _SC_THREAD_THREADS_MAX,
\r
2309 _SC_THREAD_ATTR_STACKADDR,
\r
2311 _SC_THREAD_ATTR_STACKSIZE,
\r
2313 _SC_THREAD_PRIORITY_SCHEDULING,
\r
2315 _SC_THREAD_PRIO_INHERIT,
\r
2317 _SC_THREAD_PRIO_PROTECT,
\r
2319 _SC_THREAD_PROCESS_SHARED,
\r
2322 _SC_NPROCESSORS_CONF,
\r
2324 _SC_NPROCESSORS_ONLN,
\r
2335 _SC_XOPEN_VERSION,
\r
2337 _SC_XOPEN_XCU_VERSION,
\r
2343 _SC_XOPEN_ENH_I18N,
\r
2412 _SC_XBS5_ILP32_OFF32,
\r
2414 _SC_XBS5_ILP32_OFFBIG,
\r
2416 _SC_XBS5_LP64_OFF64,
\r
2418 _SC_XBS5_LPBIG_OFFBIG,
\r
2423 _SC_XOPEN_REALTIME,
\r
2425 _SC_XOPEN_REALTIME_THREADS,
\r
2428 _SC_ADVISORY_INFO,
\r
2434 _SC_C_LANG_SUPPORT,
\r
2436 _SC_C_LANG_SUPPORT_R,
\r
2438 _SC_CLOCK_SELECTION,
\r
2442 _SC_THREAD_CPUTIME,
\r
2446 _SC_DEVICE_SPECIFIC,
\r
2448 _SC_DEVICE_SPECIFIC_R,
\r
2456 _SC_FILE_ATTRIBUTES,
\r
2462 _SC_MONOTONIC_CLOCK,
\r
2464 _SC_MULTI_PROCESS,
\r
2466 _SC_SINGLE_PROCESS,
\r
2470 _SC_READER_WRITER_LOCKS,
\r
2476 _SC_REGEX_VERSION,
\r
2484 _SC_SPORADIC_SERVER,
\r
2486 _SC_THREAD_SPORADIC_SERVER,
\r
2488 _SC_SYSTEM_DATABASE,
\r
2490 _SC_SYSTEM_DATABASE_R,
\r
2494 _SC_TYPED_MEMORY_OBJECTS,
\r
2498 _SC_USER_GROUPS_R,
\r
2502 _SC_2_PBS_ACCOUNTING,
\r
2506 _SC_2_PBS_MESSAGE,
\r
2514 _SC_2_PBS_CHECKPOINT,
\r
2517 _SC_V6_ILP32_OFF32,
\r
2519 _SC_V6_ILP32_OFFBIG,
\r
2521 _SC_V6_LP64_OFF64,
\r
2523 _SC_V6_LPBIG_OFFBIG,
\r
2526 _SC_HOST_NAME_MAX,
\r
2530 _SC_TRACE_EVENT_FILTER,
\r
2532 _SC_TRACE_INHERIT,
\r
2537 _SC_LEVEL1_ICACHE_SIZE,
\r
2539 _SC_LEVEL1_ICACHE_ASSOC,
\r
2541 _SC_LEVEL1_ICACHE_LINESIZE,
\r
2543 _SC_LEVEL1_DCACHE_SIZE,
\r
2545 _SC_LEVEL1_DCACHE_ASSOC,
\r
2547 _SC_LEVEL1_DCACHE_LINESIZE,
\r
2549 _SC_LEVEL2_CACHE_SIZE,
\r
2551 _SC_LEVEL2_CACHE_ASSOC,
\r
2553 _SC_LEVEL2_CACHE_LINESIZE,
\r
2555 _SC_LEVEL3_CACHE_SIZE,
\r
2557 _SC_LEVEL3_CACHE_ASSOC,
\r
2559 _SC_LEVEL3_CACHE_LINESIZE,
\r
2561 _SC_LEVEL4_CACHE_SIZE,
\r
2563 _SC_LEVEL4_CACHE_ASSOC,
\r
2565 _SC_LEVEL4_CACHE_LINESIZE,
\r
2569 _SC_IPV6 = _SC_LEVEL1_ICACHE_SIZE + 50,
\r
2574 _SC_V7_ILP32_OFF32,
\r
2576 _SC_V7_ILP32_OFFBIG,
\r
2578 _SC_V7_LP64_OFF64,
\r
2580 _SC_V7_LPBIG_OFFBIG,
\r
2586 _SC_TRACE_EVENT_NAME_MAX,
\r
2588 _SC_TRACE_NAME_MAX,
\r
2590 _SC_TRACE_SYS_MAX,
\r
2592 _SC_TRACE_USER_EVENT_MAX,
\r
2595 _SC_XOPEN_STREAMS,
\r
2598 _SC_THREAD_ROBUST_PRIO_INHERIT,
\r
2600 _SC_THREAD_ROBUST_PRIO_PROTECT
\r
2610 _CS_V6_WIDTH_RESTRICTED_ENVS,
\r
2614 _CS_GNU_LIBC_VERSION,
\r
2616 _CS_GNU_LIBPTHREAD_VERSION,
\r
2619 _CS_V5_WIDTH_RESTRICTED_ENVS,
\r
2623 _CS_V7_WIDTH_RESTRICTED_ENVS,
\r
2627 _CS_LFS_CFLAGS = 1000,
\r
2633 _CS_LFS_LINTFLAGS,
\r
2637 _CS_LFS64_LDFLAGS,
\r
2641 _CS_LFS64_LINTFLAGS,
\r
2644 _CS_XBS5_ILP32_OFF32_CFLAGS = 1100,
\r
2646 _CS_XBS5_ILP32_OFF32_LDFLAGS,
\r
2648 _CS_XBS5_ILP32_OFF32_LIBS,
\r
2650 _CS_XBS5_ILP32_OFF32_LINTFLAGS,
\r
2652 _CS_XBS5_ILP32_OFFBIG_CFLAGS,
\r
2654 _CS_XBS5_ILP32_OFFBIG_LDFLAGS,
\r
2656 _CS_XBS5_ILP32_OFFBIG_LIBS,
\r
2658 _CS_XBS5_ILP32_OFFBIG_LINTFLAGS,
\r
2660 _CS_XBS5_LP64_OFF64_CFLAGS,
\r
2662 _CS_XBS5_LP64_OFF64_LDFLAGS,
\r
2664 _CS_XBS5_LP64_OFF64_LIBS,
\r
2666 _CS_XBS5_LP64_OFF64_LINTFLAGS,
\r
2668 _CS_XBS5_LPBIG_OFFBIG_CFLAGS,
\r
2670 _CS_XBS5_LPBIG_OFFBIG_LDFLAGS,
\r
2672 _CS_XBS5_LPBIG_OFFBIG_LIBS,
\r
2674 _CS_XBS5_LPBIG_OFFBIG_LINTFLAGS,
\r
2677 _CS_POSIX_V6_ILP32_OFF32_CFLAGS,
\r
2679 _CS_POSIX_V6_ILP32_OFF32_LDFLAGS,
\r
2681 _CS_POSIX_V6_ILP32_OFF32_LIBS,
\r
2683 _CS_POSIX_V6_ILP32_OFF32_LINTFLAGS,
\r
2685 _CS_POSIX_V6_ILP32_OFFBIG_CFLAGS,
\r
2687 _CS_POSIX_V6_ILP32_OFFBIG_LDFLAGS,
\r
2689 _CS_POSIX_V6_ILP32_OFFBIG_LIBS,
\r
2691 _CS_POSIX_V6_ILP32_OFFBIG_LINTFLAGS,
\r
2693 _CS_POSIX_V6_LP64_OFF64_CFLAGS,
\r
2695 _CS_POSIX_V6_LP64_OFF64_LDFLAGS,
\r
2697 _CS_POSIX_V6_LP64_OFF64_LIBS,
\r
2699 _CS_POSIX_V6_LP64_OFF64_LINTFLAGS,
\r
2701 _CS_POSIX_V6_LPBIG_OFFBIG_CFLAGS,
\r
2703 _CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS,
\r
2705 _CS_POSIX_V6_LPBIG_OFFBIG_LIBS,
\r
2707 _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS,
\r
2710 _CS_POSIX_V7_ILP32_OFF32_CFLAGS,
\r
2712 _CS_POSIX_V7_ILP32_OFF32_LDFLAGS,
\r
2714 _CS_POSIX_V7_ILP32_OFF32_LIBS,
\r
2716 _CS_POSIX_V7_ILP32_OFF32_LINTFLAGS,
\r
2718 _CS_POSIX_V7_ILP32_OFFBIG_CFLAGS,
\r
2720 _CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS,
\r
2722 _CS_POSIX_V7_ILP32_OFFBIG_LIBS,
\r
2724 _CS_POSIX_V7_ILP32_OFFBIG_LINTFLAGS,
\r
2726 _CS_POSIX_V7_LP64_OFF64_CFLAGS,
\r
2728 _CS_POSIX_V7_LP64_OFF64_LDFLAGS,
\r
2730 _CS_POSIX_V7_LP64_OFF64_LIBS,
\r
2732 _CS_POSIX_V7_LP64_OFF64_LINTFLAGS,
\r
2734 _CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS,
\r
2736 _CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS,
\r
2738 _CS_POSIX_V7_LPBIG_OFFBIG_LIBS,
\r
2740 _CS_POSIX_V7_LPBIG_OFFBIG_LINTFLAGS,
\r
2748 # 610 "/usr/include/unistd.h" 2 3 4
\r
2751 extern long int pathconf (const char *__path, int __name)
\r
2752 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
2755 extern long int fpathconf (int __fd, int __name) __attribute__ ((__nothrow__ ));
\r
2758 extern long int sysconf (int __name) __attribute__ ((__nothrow__ ));
\r
2762 extern size_t confstr (int __name, char *__buf, size_t __len) __attribute__ ((__nothrow__ ));
\r
2767 extern __pid_t getpid (void) __attribute__ ((__nothrow__ ));
\r
2770 extern __pid_t getppid (void) __attribute__ ((__nothrow__ ));
\r
2773 extern __pid_t getpgrp (void) __attribute__ ((__nothrow__ ));
\r
2776 extern __pid_t __getpgid (__pid_t __pid) __attribute__ ((__nothrow__ ));
\r
2778 extern __pid_t getpgid (__pid_t __pid) __attribute__ ((__nothrow__ ));
\r
2785 extern int setpgid (__pid_t __pid, __pid_t __pgid) __attribute__ ((__nothrow__ ));
\r
2786 # 660 "/usr/include/unistd.h" 3 4
\r
2787 extern int setpgrp (void) __attribute__ ((__nothrow__ ));
\r
2794 extern __pid_t setsid (void) __attribute__ ((__nothrow__ ));
\r
2798 extern __pid_t getsid (__pid_t __pid) __attribute__ ((__nothrow__ ));
\r
2802 extern __uid_t getuid (void) __attribute__ ((__nothrow__ ));
\r
2805 extern __uid_t geteuid (void) __attribute__ ((__nothrow__ ));
\r
2808 extern __gid_t getgid (void) __attribute__ ((__nothrow__ ));
\r
2811 extern __gid_t getegid (void) __attribute__ ((__nothrow__ ));
\r
2816 extern int getgroups (int __size, __gid_t __list[]) __attribute__ ((__nothrow__ )) ;
\r
2817 # 700 "/usr/include/unistd.h" 3 4
\r
2818 extern int setuid (__uid_t __uid) __attribute__ ((__nothrow__ )) ;
\r
2823 extern int setreuid (__uid_t __ruid, __uid_t __euid) __attribute__ ((__nothrow__ )) ;
\r
2828 extern int seteuid (__uid_t __uid) __attribute__ ((__nothrow__ )) ;
\r
2835 extern int setgid (__gid_t __gid) __attribute__ ((__nothrow__ )) ;
\r
2840 extern int setregid (__gid_t __rgid, __gid_t __egid) __attribute__ ((__nothrow__ )) ;
\r
2845 extern int setegid (__gid_t __gid) __attribute__ ((__nothrow__ )) ;
\r
2846 # 756 "/usr/include/unistd.h" 3 4
\r
2847 extern __pid_t fork (void) __attribute__ ((__nothrow__));
\r
2855 extern __pid_t vfork (void) __attribute__ ((__nothrow__ ));
\r
2861 extern char *ttyname (int __fd) __attribute__ ((__nothrow__ ));
\r
2865 extern int ttyname_r (int __fd, char *__buf, size_t __buflen)
\r
2866 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2))) ;
\r
2870 extern int isatty (int __fd) __attribute__ ((__nothrow__ ));
\r
2876 extern int ttyslot (void) __attribute__ ((__nothrow__ ));
\r
2881 extern int link (const char *__from, const char *__to)
\r
2882 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2))) ;
\r
2887 extern int linkat (int __fromfd, const char *__from, int __tofd,
\r
2888 const char *__to, int __flags)
\r
2889 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2, 4))) ;
\r
2894 extern int symlink (const char *__from, const char *__to)
\r
2895 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2))) ;
\r
2900 extern ssize_t readlink (const char *__restrict __path,
\r
2901 char *__restrict __buf, size_t __len)
\r
2902 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2))) ;
\r
2907 extern int symlinkat (const char *__from, int __tofd,
\r
2908 const char *__to) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 3))) ;
\r
2911 extern ssize_t readlinkat (int __fd, const char *__restrict __path,
\r
2912 char *__restrict __buf, size_t __len)
\r
2913 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2, 3))) ;
\r
2917 extern int unlink (const char *__name) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
2921 extern int unlinkat (int __fd, const char *__name, int __flag)
\r
2922 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2)));
\r
2926 extern int rmdir (const char *__path) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
2930 extern __pid_t tcgetpgrp (int __fd) __attribute__ ((__nothrow__ ));
\r
2933 extern int tcsetpgrp (int __fd, __pid_t __pgrp_id) __attribute__ ((__nothrow__ ));
\r
2940 extern char *getlogin (void);
\r
2948 extern int getlogin_r (char *__name, size_t __name_len) __attribute__ ((__nonnull__ (1)));
\r
2953 extern int setlogin (const char *__name) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
2954 # 871 "/usr/include/unistd.h" 3 4
\r
2955 # 1 "/usr/include/getopt.h" 1 3 4
\r
2956 # 57 "/usr/include/getopt.h" 3 4
\r
2957 extern char *optarg;
\r
2958 # 71 "/usr/include/getopt.h" 3 4
\r
2959 extern int optind;
\r
2964 extern int opterr;
\r
2968 extern int optopt;
\r
2969 # 150 "/usr/include/getopt.h" 3 4
\r
2970 extern int getopt (int ___argc, char *const *___argv, const char *__shortopts)
\r
2971 __attribute__ ((__nothrow__ ));
\r
2972 # 872 "/usr/include/unistd.h" 2 3 4
\r
2980 extern int gethostname (char *__name, size_t __len) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
2987 extern int sethostname (const char *__name, size_t __len)
\r
2988 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1))) ;
\r
2992 extern int sethostid (long int __id) __attribute__ ((__nothrow__ )) ;
\r
2998 extern int getdomainname (char *__name, size_t __len)
\r
2999 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1))) ;
\r
3000 extern int setdomainname (const char *__name, size_t __len)
\r
3001 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1))) ;
\r
3007 extern int vhangup (void) __attribute__ ((__nothrow__ ));
\r
3010 extern int revoke (const char *__file) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1))) ;
\r
3018 extern int profil (unsigned short int *__sample_buffer, size_t __size,
\r
3019 size_t __offset, unsigned int __scale)
\r
3020 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
3026 extern int acct (const char *__name) __attribute__ ((__nothrow__ ));
\r
3030 extern char *getusershell (void) __attribute__ ((__nothrow__ ));
\r
3031 extern void endusershell (void) __attribute__ ((__nothrow__ ));
\r
3032 extern void setusershell (void) __attribute__ ((__nothrow__ ));
\r
3038 extern int daemon (int __nochdir, int __noclose) __attribute__ ((__nothrow__ )) ;
\r
3045 extern int chroot (const char *__path) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1))) ;
\r
3049 extern char *getpass (const char *__prompt) __attribute__ ((__nonnull__ (1)));
\r
3057 extern int fsync (int __fd);
\r
3058 # 969 "/usr/include/unistd.h" 3 4
\r
3059 extern long int gethostid (void);
\r
3062 extern void sync (void) __attribute__ ((__nothrow__ ));
\r
3068 extern int getpagesize (void) __attribute__ ((__nothrow__ )) __attribute__ ((__const__));
\r
3073 extern int getdtablesize (void) __attribute__ ((__nothrow__ ));
\r
3074 # 993 "/usr/include/unistd.h" 3 4
\r
3075 extern int truncate (const char *__file, __off_t __length)
\r
3076 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1))) ;
\r
3077 # 1016 "/usr/include/unistd.h" 3 4
\r
3078 extern int ftruncate (int __fd, __off_t __length) __attribute__ ((__nothrow__ )) ;
\r
3079 # 1037 "/usr/include/unistd.h" 3 4
\r
3080 extern int brk (void *__addr) __attribute__ ((__nothrow__ )) ;
\r
3086 extern void *sbrk (intptr_t __delta) __attribute__ ((__nothrow__ ));
\r
3087 # 1058 "/usr/include/unistd.h" 3 4
\r
3088 extern long int syscall (long int __sysno, ...) __attribute__ ((__nothrow__ ));
\r
3089 # 1081 "/usr/include/unistd.h" 3 4
\r
3090 extern int lockf (int __fd, int __cmd, __off_t __len) ;
\r
3091 # 1112 "/usr/include/unistd.h" 3 4
\r
3092 extern int fdatasync (int __fildes);
\r
3093 # 29 "./../test/abts.h" 2
\r
3094 # 41 "./../test/abts.h"
\r
3095 struct sub_suite {
\r
3101 struct sub_suite *next;
\r
3103 typedef struct sub_suite sub_suite;
\r
3105 struct abts_suite {
\r
3109 typedef struct abts_suite abts_suite;
\r
3111 struct abts_case {
\r
3115 typedef struct abts_case abts_case;
\r
3117 typedef void (*test_func)(abts_case *tc, void *data);
\r
3121 abts_suite *abts_add_suite(abts_suite *suite, const char *suite_name);
\r
3122 void abts_run_test(abts_suite *ts, test_func f, void *value);
\r
3123 void abts_log_message(const char *fmt, ...);
\r
3125 void abts_int_equal(abts_case *tc, const int expected, const int actual, int lineno);
\r
3126 void abts_int_nequal(abts_case *tc, const int expected, const int actual, int lineno);
\r
3127 void abts_str_equal(abts_case *tc, const char *expected, const char *actual, int lineno);
\r
3128 void abts_str_nequal(abts_case *tc, const char *expected, const char *actual,
\r
3129 size_t n, int lineno);
\r
3130 void abts_ptr_notnull(abts_case *tc, const void *ptr, int lineno);
\r
3131 void abts_ptr_equal(abts_case *tc, const void *expected, const void *actual, int lineno);
\r
3132 void abts_true(abts_case *tc, int condition, int lineno);
\r
3133 void abts_fail(abts_case *tc, const char *message, int lineno);
\r
3134 void abts_not_impl(abts_case *tc, const char *message, int lineno);
\r
3135 void abts_assert(abts_case *tc, const char *message, int condition, int lineno);
\r
3136 void abts_size_equal(abts_case *tc, size_t expected, size_t actual, int lineno);
\r
3137 # 99 "./../test/abts.h"
\r
3138 abts_suite *run_tests(abts_suite *suite);
\r
3139 abts_suite *run_tests1(abts_suite *suite);
\r
3141 # 1 "./../test/testutil.h" 1
\r
3142 # 17 "./../test/testutil.h"
\r
3143 # 1 "../include/apr_pools.h" 1
\r
3144 # 43 "../include/apr_pools.h"
\r
3145 # 1 "../include/apr.h" 1
\r
3146 # 168 "../include/apr.h"
\r
3147 # 1 "/usr/include/x86_64-linux-gnu/sys/socket.h" 1 3 4
\r
3148 # 26 "/usr/include/x86_64-linux-gnu/sys/socket.h" 3 4
\r
3149 # 1 "/usr/include/x86_64-linux-gnu/sys/uio.h" 1 3 4
\r
3150 # 28 "/usr/include/x86_64-linux-gnu/sys/uio.h" 3 4
\r
3151 # 1 "/usr/include/x86_64-linux-gnu/bits/uio.h" 1 3 4
\r
3152 # 43 "/usr/include/x86_64-linux-gnu/bits/uio.h" 3 4
\r
3158 # 29 "/usr/include/x86_64-linux-gnu/sys/uio.h" 2 3 4
\r
3159 # 39 "/usr/include/x86_64-linux-gnu/sys/uio.h" 3 4
\r
3160 extern ssize_t readv (int __fd, const struct iovec *__iovec, int __count)
\r
3162 # 50 "/usr/include/x86_64-linux-gnu/sys/uio.h" 3 4
\r
3163 extern ssize_t writev (int __fd, const struct iovec *__iovec, int __count)
\r
3165 # 65 "/usr/include/x86_64-linux-gnu/sys/uio.h" 3 4
\r
3166 extern ssize_t preadv (int __fd, const struct iovec *__iovec, int __count,
\r
3167 __off_t __offset) ;
\r
3168 # 77 "/usr/include/x86_64-linux-gnu/sys/uio.h" 3 4
\r
3169 extern ssize_t pwritev (int __fd, const struct iovec *__iovec, int __count,
\r
3170 __off_t __offset) ;
\r
3171 # 27 "/usr/include/x86_64-linux-gnu/sys/socket.h" 2 3 4
\r
3173 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stddef.h" 1 3 4
\r
3174 # 29 "/usr/include/x86_64-linux-gnu/sys/socket.h" 2 3 4
\r
3175 # 38 "/usr/include/x86_64-linux-gnu/sys/socket.h" 3 4
\r
3176 # 1 "/usr/include/x86_64-linux-gnu/bits/socket.h" 1 3 4
\r
3177 # 27 "/usr/include/x86_64-linux-gnu/bits/socket.h" 3 4
\r
3178 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stddef.h" 1 3 4
\r
3179 # 28 "/usr/include/x86_64-linux-gnu/bits/socket.h" 2 3 4
\r
3180 # 38 "/usr/include/x86_64-linux-gnu/bits/socket.h" 3 4
\r
3181 # 1 "/usr/include/x86_64-linux-gnu/bits/socket_type.h" 1 3 4
\r
3182 # 24 "/usr/include/x86_64-linux-gnu/bits/socket_type.h" 3 4
\r
3183 enum __socket_type
\r
3195 SOCK_SEQPACKET = 5,
\r
3208 SOCK_CLOEXEC = 02000000,
\r
3211 SOCK_NONBLOCK = 00004000
\r
3215 # 39 "/usr/include/x86_64-linux-gnu/bits/socket.h" 2 3 4
\r
3216 # 146 "/usr/include/x86_64-linux-gnu/bits/socket.h" 3 4
\r
3217 # 1 "/usr/include/x86_64-linux-gnu/bits/sockaddr.h" 1 3 4
\r
3218 # 28 "/usr/include/x86_64-linux-gnu/bits/sockaddr.h" 3 4
\r
3219 typedef unsigned short int sa_family_t;
\r
3220 # 147 "/usr/include/x86_64-linux-gnu/bits/socket.h" 2 3 4
\r
3225 sa_family_t sa_family;
\r
3228 # 162 "/usr/include/x86_64-linux-gnu/bits/socket.h" 3 4
\r
3229 struct sockaddr_storage
\r
3231 sa_family_t ss_family;
\r
3232 unsigned long int __ss_align;
\r
3233 char __ss_padding[(128 - (2 * sizeof (unsigned long int)))];
\r
3244 MSG_DONTROUTE = 0x04,
\r
3251 MSG_CTRUNC = 0x08,
\r
3257 MSG_DONTWAIT = 0x40,
\r
3261 MSG_WAITALL = 0x100,
\r
3267 MSG_CONFIRM = 0x800,
\r
3271 MSG_ERRQUEUE = 0x2000,
\r
3273 MSG_NOSIGNAL = 0x4000,
\r
3275 MSG_MORE = 0x8000,
\r
3277 MSG_WAITFORONE = 0x10000,
\r
3279 MSG_FASTOPEN = 0x20000000,
\r
3282 MSG_CMSG_CLOEXEC = 0x40000000
\r
3294 socklen_t msg_namelen;
\r
3296 struct iovec *msg_iov;
\r
3297 size_t msg_iovlen;
\r
3299 void *msg_control;
\r
3300 size_t msg_controllen;
\r
3319 __extension__ unsigned char __cmsg_data [];
\r
3322 # 272 "/usr/include/x86_64-linux-gnu/bits/socket.h" 3 4
\r
3323 extern struct cmsghdr *__cmsg_nxthdr (struct msghdr *__mhdr,
\r
3324 struct cmsghdr *__cmsg) __attribute__ ((__nothrow__ ));
\r
3325 # 299 "/usr/include/x86_64-linux-gnu/bits/socket.h" 3 4
\r
3335 # 345 "/usr/include/x86_64-linux-gnu/bits/socket.h" 3 4
\r
3336 # 1 "/usr/include/x86_64-linux-gnu/asm/socket.h" 1 3 4
\r
3337 # 1 "/usr/include/asm-generic/socket.h" 1 3 4
\r
3341 # 1 "/usr/include/x86_64-linux-gnu/asm/sockios.h" 1 3 4
\r
3342 # 1 "/usr/include/asm-generic/sockios.h" 1 3 4
\r
3343 # 2 "/usr/include/x86_64-linux-gnu/asm/sockios.h" 2 3 4
\r
3344 # 5 "/usr/include/asm-generic/socket.h" 2 3 4
\r
3345 # 2 "/usr/include/x86_64-linux-gnu/asm/socket.h" 2 3 4
\r
3346 # 346 "/usr/include/x86_64-linux-gnu/bits/socket.h" 2 3 4
\r
3347 # 379 "/usr/include/x86_64-linux-gnu/bits/socket.h" 3 4
\r
3353 # 39 "/usr/include/x86_64-linux-gnu/sys/socket.h" 2 3 4
\r
3360 unsigned short int sa_family;
\r
3361 unsigned char sa_data[14];
\r
3376 # 113 "/usr/include/x86_64-linux-gnu/sys/socket.h" 3 4
\r
3377 extern int socket (int __domain, int __type, int __protocol) __attribute__ ((__nothrow__ ));
\r
3383 extern int socketpair (int __domain, int __type, int __protocol,
\r
3384 int __fds[2]) __attribute__ ((__nothrow__ ));
\r
3387 extern int bind (int __fd, const struct sockaddr * __addr, socklen_t __len)
\r
3388 __attribute__ ((__nothrow__ ));
\r
3391 extern int getsockname (int __fd, struct sockaddr *__restrict __addr,
\r
3392 socklen_t *__restrict __len) __attribute__ ((__nothrow__ ));
\r
3393 # 137 "/usr/include/x86_64-linux-gnu/sys/socket.h" 3 4
\r
3394 extern int connect (int __fd, const struct sockaddr * __addr, socklen_t __len);
\r
3398 extern int getpeername (int __fd, struct sockaddr *__restrict __addr,
\r
3399 socklen_t *__restrict __len) __attribute__ ((__nothrow__ ));
\r
3406 extern ssize_t send (int __fd, const void *__buf, size_t __n, int __flags);
\r
3413 extern ssize_t recv (int __fd, void *__buf, size_t __n, int __flags);
\r
3420 extern ssize_t sendto (int __fd, const void *__buf, size_t __n,
\r
3421 int __flags, const struct sockaddr * __addr,
\r
3422 socklen_t __addr_len);
\r
3423 # 174 "/usr/include/x86_64-linux-gnu/sys/socket.h" 3 4
\r
3424 extern ssize_t recvfrom (int __fd, void *__restrict __buf, size_t __n,
\r
3425 int __flags, struct sockaddr *__restrict __addr,
\r
3426 socklen_t *__restrict __addr_len);
\r
3434 extern ssize_t sendmsg (int __fd, const struct msghdr *__message,
\r
3436 # 202 "/usr/include/x86_64-linux-gnu/sys/socket.h" 3 4
\r
3437 extern ssize_t recvmsg (int __fd, struct msghdr *__message, int __flags);
\r
3438 # 219 "/usr/include/x86_64-linux-gnu/sys/socket.h" 3 4
\r
3439 extern int getsockopt (int __fd, int __level, int __optname,
\r
3440 void *__restrict __optval,
\r
3441 socklen_t *__restrict __optlen) __attribute__ ((__nothrow__ ));
\r
3446 extern int setsockopt (int __fd, int __level, int __optname,
\r
3447 const void *__optval, socklen_t __optlen) __attribute__ ((__nothrow__ ));
\r
3453 extern int listen (int __fd, int __n) __attribute__ ((__nothrow__ ));
\r
3454 # 243 "/usr/include/x86_64-linux-gnu/sys/socket.h" 3 4
\r
3455 extern int accept (int __fd, struct sockaddr *__restrict __addr,
\r
3456 socklen_t *__restrict __addr_len);
\r
3457 # 261 "/usr/include/x86_64-linux-gnu/sys/socket.h" 3 4
\r
3458 extern int shutdown (int __fd, int __how) __attribute__ ((__nothrow__ ));
\r
3463 extern int sockatmark (int __fd) __attribute__ ((__nothrow__ ));
\r
3471 extern int isfdtype (int __fd, int __fdtype) __attribute__ ((__nothrow__ ));
\r
3472 # 169 "../include/apr.h" 2
\r
3473 # 178 "../include/apr.h"
\r
3474 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stdint.h" 1 3
\r
3475 # 61 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stdint.h" 3
\r
3476 # 1 "/usr/bin/../lib/gcc/x86_64-linux-gnu/4.9/include/stdint.h" 1 3 4
\r
3485 # 1 "/usr/include/stdint.h" 1 3 4
\r
3486 # 26 "/usr/include/stdint.h" 3 4
\r
3487 # 1 "/usr/include/x86_64-linux-gnu/bits/wchar.h" 1 3 4
\r
3488 # 27 "/usr/include/stdint.h" 2 3 4
\r
3489 # 1 "/usr/include/x86_64-linux-gnu/bits/wordsize.h" 1 3 4
\r
3490 # 28 "/usr/include/stdint.h" 2 3 4
\r
3491 # 48 "/usr/include/stdint.h" 3 4
\r
3492 typedef unsigned char uint8_t;
\r
3493 typedef unsigned short int uint16_t;
\r
3495 typedef unsigned int uint32_t;
\r
3499 typedef unsigned long int uint64_t;
\r
3500 # 65 "/usr/include/stdint.h" 3 4
\r
3501 typedef signed char int_least8_t;
\r
3502 typedef short int int_least16_t;
\r
3503 typedef int int_least32_t;
\r
3505 typedef long int int_least64_t;
\r
3512 typedef unsigned char uint_least8_t;
\r
3513 typedef unsigned short int uint_least16_t;
\r
3514 typedef unsigned int uint_least32_t;
\r
3516 typedef unsigned long int uint_least64_t;
\r
3517 # 90 "/usr/include/stdint.h" 3 4
\r
3518 typedef signed char int_fast8_t;
\r
3520 typedef long int int_fast16_t;
\r
3521 typedef long int int_fast32_t;
\r
3522 typedef long int int_fast64_t;
\r
3523 # 103 "/usr/include/stdint.h" 3 4
\r
3524 typedef unsigned char uint_fast8_t;
\r
3526 typedef unsigned long int uint_fast16_t;
\r
3527 typedef unsigned long int uint_fast32_t;
\r
3528 typedef unsigned long int uint_fast64_t;
\r
3529 # 122 "/usr/include/stdint.h" 3 4
\r
3530 typedef unsigned long int uintptr_t;
\r
3531 # 134 "/usr/include/stdint.h" 3 4
\r
3532 typedef long int intmax_t;
\r
3533 typedef unsigned long int uintmax_t;
\r
3534 # 10 "/usr/bin/../lib/gcc/x86_64-linux-gnu/4.9/include/stdint.h" 2 3 4
\r
3535 # 62 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stdint.h" 2 3
\r
3536 # 179 "../include/apr.h" 2
\r
3540 # 1 "/usr/include/x86_64-linux-gnu/sys/wait.h" 1 3 4
\r
3541 # 29 "/usr/include/x86_64-linux-gnu/sys/wait.h" 3 4
\r
3542 # 1 "/usr/include/signal.h" 1 3 4
\r
3543 # 32 "/usr/include/signal.h" 3 4
\r
3544 # 1 "/usr/include/x86_64-linux-gnu/bits/sigset.h" 1 3 4
\r
3545 # 102 "/usr/include/x86_64-linux-gnu/bits/sigset.h" 3 4
\r
3546 extern int __sigismember (const __sigset_t *, int);
\r
3547 extern int __sigaddset (__sigset_t *, int);
\r
3548 extern int __sigdelset (__sigset_t *, int);
\r
3549 # 33 "/usr/include/signal.h" 2 3 4
\r
3557 typedef __sig_atomic_t sig_atomic_t;
\r
3558 # 57 "/usr/include/signal.h" 3 4
\r
3559 # 1 "/usr/include/x86_64-linux-gnu/bits/signum.h" 1 3 4
\r
3560 # 58 "/usr/include/signal.h" 2 3 4
\r
3561 # 75 "/usr/include/signal.h" 3 4
\r
3562 # 1 "/usr/include/time.h" 1 3 4
\r
3563 # 76 "/usr/include/signal.h" 2 3 4
\r
3568 # 1 "/usr/include/x86_64-linux-gnu/bits/siginfo.h" 1 3 4
\r
3569 # 24 "/usr/include/x86_64-linux-gnu/bits/siginfo.h" 3 4
\r
3570 # 1 "/usr/include/x86_64-linux-gnu/bits/wordsize.h" 1 3 4
\r
3571 # 25 "/usr/include/x86_64-linux-gnu/bits/siginfo.h" 2 3 4
\r
3579 typedef union sigval
\r
3584 # 58 "/usr/include/x86_64-linux-gnu/bits/siginfo.h" 3 4
\r
3585 typedef __clock_t __sigchld_clock_t;
\r
3598 int _pad[((128 / sizeof (int)) - 4)];
\r
3612 sigval_t si_sigval;
\r
3620 sigval_t si_sigval;
\r
3629 __sigchld_clock_t si_utime;
\r
3630 __sigchld_clock_t si_stime;
\r
3637 short int si_addr_lsb;
\r
3652 unsigned int _arch;
\r
3656 # 153 "/usr/include/x86_64-linux-gnu/bits/siginfo.h" 3 4
\r
3788 # 307 "/usr/include/x86_64-linux-gnu/bits/siginfo.h" 3 4
\r
3789 typedef struct sigevent
\r
3791 sigval_t sigev_value;
\r
3797 int _pad[((64 / sizeof (int)) - 4)];
\r
3805 void (*_function) (sigval_t);
\r
3806 pthread_attr_t *_attribute;
\r
3825 SIGEV_THREAD_ID = 4
\r
3828 # 81 "/usr/include/signal.h" 2 3 4
\r
3833 typedef void (*__sighandler_t) (int);
\r
3838 extern __sighandler_t __sysv_signal (int __sig, __sighandler_t __handler)
\r
3839 __attribute__ ((__nothrow__ ));
\r
3840 # 102 "/usr/include/signal.h" 3 4
\r
3841 extern __sighandler_t signal (int __sig, __sighandler_t __handler)
\r
3842 __attribute__ ((__nothrow__ ));
\r
3843 # 127 "/usr/include/signal.h" 3 4
\r
3844 extern int kill (__pid_t __pid, int __sig) __attribute__ ((__nothrow__ ));
\r
3851 extern int killpg (__pid_t __pgrp, int __sig) __attribute__ ((__nothrow__ ));
\r
3856 extern int raise (int __sig) __attribute__ ((__nothrow__ ));
\r
3861 extern __sighandler_t ssignal (int __sig, __sighandler_t __handler)
\r
3862 __attribute__ ((__nothrow__ ));
\r
3863 extern int gsignal (int __sig) __attribute__ ((__nothrow__ ));
\r
3868 extern void psignal (int __sig, const char *__s);
\r
3873 extern void psiginfo (const siginfo_t *__pinfo, const char *__s);
\r
3874 # 167 "/usr/include/signal.h" 3 4
\r
3875 extern int __sigpause (int __sig_or_mask, int __is_sig);
\r
3876 # 189 "/usr/include/signal.h" 3 4
\r
3877 extern int sigblock (int __mask) __attribute__ ((__nothrow__ )) __attribute__ ((__deprecated__));
\r
3880 extern int sigsetmask (int __mask) __attribute__ ((__nothrow__ )) __attribute__ ((__deprecated__));
\r
3883 extern int siggetmask (void) __attribute__ ((__nothrow__ )) __attribute__ ((__deprecated__));
\r
3884 # 209 "/usr/include/signal.h" 3 4
\r
3885 typedef __sighandler_t sig_t;
\r
3891 extern int sigemptyset (sigset_t *__set) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
3894 extern int sigfillset (sigset_t *__set) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
3897 extern int sigaddset (sigset_t *__set, int __signo) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
3900 extern int sigdelset (sigset_t *__set, int __signo) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
3903 extern int sigismember (const sigset_t *__set, int __signo)
\r
3904 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
3905 # 245 "/usr/include/signal.h" 3 4
\r
3906 # 1 "/usr/include/x86_64-linux-gnu/bits/sigaction.h" 1 3 4
\r
3907 # 24 "/usr/include/x86_64-linux-gnu/bits/sigaction.h" 3 4
\r
3915 __sighandler_t sa_handler;
\r
3917 void (*sa_sigaction) (int, siginfo_t *, void *);
\r
3919 __sigaction_handler;
\r
3927 __sigset_t sa_mask;
\r
3933 void (*sa_restorer) (void);
\r
3935 # 246 "/usr/include/signal.h" 2 3 4
\r
3938 extern int sigprocmask (int __how, const sigset_t *__restrict __set,
\r
3939 sigset_t *__restrict __oset) __attribute__ ((__nothrow__ ));
\r
3946 extern int sigsuspend (const sigset_t *__set) __attribute__ ((__nonnull__ (1)));
\r
3949 extern int sigaction (int __sig, const struct sigaction *__restrict __act,
\r
3950 struct sigaction *__restrict __oact) __attribute__ ((__nothrow__ ));
\r
3953 extern int sigpending (sigset_t *__set) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
3960 extern int sigwait (const sigset_t *__restrict __set, int *__restrict __sig)
\r
3961 __attribute__ ((__nonnull__ (1, 2)));
\r
3968 extern int sigwaitinfo (const sigset_t *__restrict __set,
\r
3969 siginfo_t *__restrict __info) __attribute__ ((__nonnull__ (1)));
\r
3976 extern int sigtimedwait (const sigset_t *__restrict __set,
\r
3977 siginfo_t *__restrict __info,
\r
3978 const struct timespec *__restrict __timeout)
\r
3979 __attribute__ ((__nonnull__ (1)));
\r
3983 extern int sigqueue (__pid_t __pid, int __sig, const union sigval __val)
\r
3984 __attribute__ ((__nothrow__ ));
\r
3985 # 303 "/usr/include/signal.h" 3 4
\r
3986 extern const char *const _sys_siglist[65];
\r
3987 extern const char *const sys_siglist[65];
\r
3992 __sighandler_t sv_handler;
\r
3998 # 327 "/usr/include/signal.h" 3 4
\r
3999 extern int sigvec (int __sig, const struct sigvec *__vec,
\r
4000 struct sigvec *__ovec) __attribute__ ((__nothrow__ ));
\r
4005 # 1 "/usr/include/x86_64-linux-gnu/bits/sigcontext.h" 1 3 4
\r
4006 # 29 "/usr/include/x86_64-linux-gnu/bits/sigcontext.h" 3 4
\r
4007 struct _fpx_sw_bytes
\r
4009 __uint32_t magic1;
\r
4010 __uint32_t extended_size;
\r
4011 __uint64_t xstate_bv;
\r
4012 __uint32_t xstate_size;
\r
4013 __uint32_t padding[7];
\r
4018 unsigned short significand[4];
\r
4019 unsigned short exponent;
\r
4024 unsigned short significand[4];
\r
4025 unsigned short exponent;
\r
4026 unsigned short padding[3];
\r
4031 __uint32_t element[4];
\r
4033 # 121 "/usr/include/x86_64-linux-gnu/bits/sigcontext.h" 3 4
\r
4044 __uint32_t mxcr_mask;
\r
4045 struct _fpxreg _st[8];
\r
4046 struct _xmmreg _xmm[16];
\r
4047 __uint32_t padding[24];
\r
4069 __uint64_t eflags;
\r
4070 unsigned short cs;
\r
4071 unsigned short gs;
\r
4072 unsigned short fs;
\r
4073 unsigned short __pad0;
\r
4075 __uint64_t trapno;
\r
4076 __uint64_t oldmask;
\r
4078 __extension__ union
\r
4080 struct _fpstate * fpstate;
\r
4081 __uint64_t __fpstate_word;
\r
4083 __uint64_t __reserved1 [8];
\r
4090 __uint64_t xstate_bv;
\r
4091 __uint64_t reserved1[2];
\r
4092 __uint64_t reserved2[5];
\r
4095 struct _ymmh_state
\r
4097 __uint32_t ymmh_space[64];
\r
4102 struct _fpstate fpstate;
\r
4103 struct _xsave_hdr xstate_hdr;
\r
4104 struct _ymmh_state ymmh;
\r
4106 # 333 "/usr/include/signal.h" 2 3 4
\r
4109 extern int sigreturn (struct sigcontext *__scp) __attribute__ ((__nothrow__ ));
\r
4117 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stddef.h" 1 3 4
\r
4118 # 343 "/usr/include/signal.h" 2 3 4
\r
4123 extern int siginterrupt (int __sig, int __interrupt) __attribute__ ((__nothrow__ ));
\r
4126 # 1 "/usr/include/x86_64-linux-gnu/bits/sigstack.h" 1 3 4
\r
4127 # 25 "/usr/include/x86_64-linux-gnu/bits/sigstack.h" 3 4
\r
4143 # 49 "/usr/include/x86_64-linux-gnu/bits/sigstack.h" 3 4
\r
4144 typedef struct sigaltstack
\r
4150 # 350 "/usr/include/signal.h" 2 3 4
\r
4153 # 1 "/usr/include/x86_64-linux-gnu/sys/ucontext.h" 1 3 4
\r
4154 # 22 "/usr/include/x86_64-linux-gnu/sys/ucontext.h" 3 4
\r
4155 # 1 "/usr/include/signal.h" 1 3 4
\r
4156 # 23 "/usr/include/x86_64-linux-gnu/sys/ucontext.h" 2 3 4
\r
4165 __extension__ typedef long long int greg_t;
\r
4171 typedef greg_t gregset_t[23];
\r
4172 # 92 "/usr/include/x86_64-linux-gnu/sys/ucontext.h" 3 4
\r
4173 struct _libc_fpxreg
\r
4175 unsigned short int significand[4];
\r
4176 unsigned short int exponent;
\r
4177 unsigned short int padding[3];
\r
4180 struct _libc_xmmreg
\r
4182 __uint32_t element[4];
\r
4185 struct _libc_fpstate
\r
4195 __uint32_t mxcr_mask;
\r
4196 struct _libc_fpxreg _st[8];
\r
4197 struct _libc_xmmreg _xmm[16];
\r
4198 __uint32_t padding[24];
\r
4202 typedef struct _libc_fpstate *fpregset_t;
\r
4209 fpregset_t fpregs;
\r
4210 __extension__ unsigned long long __reserved1 [8];
\r
4214 typedef struct ucontext
\r
4216 unsigned long int uc_flags;
\r
4217 struct ucontext *uc_link;
\r
4219 mcontext_t uc_mcontext;
\r
4220 __sigset_t uc_sigmask;
\r
4221 struct _libc_fpstate __fpregs_mem;
\r
4223 # 353 "/usr/include/signal.h" 2 3 4
\r
4229 extern int sigstack (struct sigstack *__ss, struct sigstack *__oss)
\r
4230 __attribute__ ((__nothrow__ )) __attribute__ ((__deprecated__));
\r
4234 extern int sigaltstack (const struct sigaltstack *__restrict __ss,
\r
4235 struct sigaltstack *__restrict __oss) __attribute__ ((__nothrow__ ));
\r
4236 # 388 "/usr/include/signal.h" 3 4
\r
4237 # 1 "/usr/include/x86_64-linux-gnu/bits/sigthread.h" 1 3 4
\r
4238 # 30 "/usr/include/x86_64-linux-gnu/bits/sigthread.h" 3 4
\r
4239 extern int pthread_sigmask (int __how,
\r
4240 const __sigset_t *__restrict __newmask,
\r
4241 __sigset_t *__restrict __oldmask)__attribute__ ((__nothrow__ ));
\r
4244 extern int pthread_kill (pthread_t __threadid, int __signo) __attribute__ ((__nothrow__ ));
\r
4245 # 389 "/usr/include/signal.h" 2 3 4
\r
4252 extern int __libc_current_sigrtmin (void) __attribute__ ((__nothrow__ ));
\r
4254 extern int __libc_current_sigrtmax (void) __attribute__ ((__nothrow__ ));
\r
4255 # 30 "/usr/include/x86_64-linux-gnu/sys/wait.h" 2 3 4
\r
4256 # 102 "/usr/include/x86_64-linux-gnu/sys/wait.h" 3 4
\r
4257 extern __pid_t wait (__WAIT_STATUS __stat_loc);
\r
4258 # 125 "/usr/include/x86_64-linux-gnu/sys/wait.h" 3 4
\r
4259 extern __pid_t waitpid (__pid_t __pid, int *__stat_loc, int __options);
\r
4260 # 135 "/usr/include/x86_64-linux-gnu/sys/wait.h" 3 4
\r
4261 # 1 "/usr/include/x86_64-linux-gnu/bits/siginfo.h" 1 3 4
\r
4262 # 24 "/usr/include/x86_64-linux-gnu/bits/siginfo.h" 3 4
\r
4263 # 1 "/usr/include/x86_64-linux-gnu/bits/wordsize.h" 1 3 4
\r
4264 # 25 "/usr/include/x86_64-linux-gnu/bits/siginfo.h" 2 3 4
\r
4265 # 136 "/usr/include/x86_64-linux-gnu/sys/wait.h" 2 3 4
\r
4266 # 148 "/usr/include/x86_64-linux-gnu/sys/wait.h" 3 4
\r
4267 extern int waitid (idtype_t __idtype, __id_t __id, siginfo_t *__infop,
\r
4281 extern __pid_t wait3 (__WAIT_STATUS __stat_loc, int __options,
\r
4282 struct rusage * __usage) __attribute__ ((__nothrow__));
\r
4287 extern __pid_t wait4 (__pid_t __pid, __WAIT_STATUS __stat_loc, int __options,
\r
4288 struct rusage *__usage) __attribute__ ((__nothrow__));
\r
4289 # 183 "../include/apr.h" 2
\r
4290 # 193 "../include/apr.h"
\r
4291 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/limits.h" 1 3
\r
4292 # 37 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/limits.h" 3
\r
4293 # 1 "/usr/include/limits.h" 1 3 4
\r
4294 # 143 "/usr/include/limits.h" 3 4
\r
4295 # 1 "/usr/include/x86_64-linux-gnu/bits/posix1_lim.h" 1 3 4
\r
4296 # 160 "/usr/include/x86_64-linux-gnu/bits/posix1_lim.h" 3 4
\r
4297 # 1 "/usr/include/x86_64-linux-gnu/bits/local_lim.h" 1 3 4
\r
4298 # 38 "/usr/include/x86_64-linux-gnu/bits/local_lim.h" 3 4
\r
4299 # 1 "/usr/include/linux/limits.h" 1 3 4
\r
4300 # 39 "/usr/include/x86_64-linux-gnu/bits/local_lim.h" 2 3 4
\r
4301 # 161 "/usr/include/x86_64-linux-gnu/bits/posix1_lim.h" 2 3 4
\r
4302 # 144 "/usr/include/limits.h" 2 3 4
\r
4306 # 1 "/usr/include/x86_64-linux-gnu/bits/posix2_lim.h" 1 3 4
\r
4307 # 148 "/usr/include/limits.h" 2 3 4
\r
4308 # 38 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/limits.h" 2 3
\r
4309 # 194 "../include/apr.h" 2
\r
4310 # 309 "../include/apr.h"
\r
4311 typedef unsigned char apr_byte_t;
\r
4313 typedef short apr_int16_t;
\r
4314 typedef unsigned short apr_uint16_t;
\r
4316 typedef int apr_int32_t;
\r
4317 typedef unsigned int apr_uint32_t;
\r
4318 # 352 "../include/apr.h"
\r
4319 typedef long apr_int64_t;
\r
4320 typedef unsigned long apr_uint64_t;
\r
4323 typedef size_t apr_size_t;
\r
4324 typedef ssize_t apr_ssize_t;
\r
4325 typedef off_t apr_off_t;
\r
4326 typedef socklen_t apr_socklen_t;
\r
4327 typedef ino_t apr_ino_t;
\r
4330 typedef apr_uint64_t apr_uintptr_t;
\r
4331 # 44 "../include/apr_pools.h" 2
\r
4332 # 1 "../include/apr_errno.h" 1
\r
4333 # 28 "../include/apr_errno.h"
\r
4334 # 1 "/usr/include/errno.h" 1 3 4
\r
4335 # 35 "/usr/include/errno.h" 3 4
\r
4336 # 1 "/usr/include/x86_64-linux-gnu/bits/errno.h" 1 3 4
\r
4337 # 24 "/usr/include/x86_64-linux-gnu/bits/errno.h" 3 4
\r
4338 # 1 "/usr/include/linux/errno.h" 1 3 4
\r
4339 # 1 "/usr/include/x86_64-linux-gnu/asm/errno.h" 1 3 4
\r
4340 # 1 "/usr/include/asm-generic/errno.h" 1 3 4
\r
4344 # 1 "/usr/include/asm-generic/errno-base.h" 1 3 4
\r
4345 # 5 "/usr/include/asm-generic/errno.h" 2 3 4
\r
4346 # 2 "/usr/include/x86_64-linux-gnu/asm/errno.h" 2 3 4
\r
4347 # 2 "/usr/include/linux/errno.h" 2 3 4
\r
4348 # 25 "/usr/include/x86_64-linux-gnu/bits/errno.h" 2 3 4
\r
4349 # 50 "/usr/include/x86_64-linux-gnu/bits/errno.h" 3 4
\r
4350 extern int *__errno_location (void) __attribute__ ((__nothrow__ )) __attribute__ ((__const__));
\r
4351 # 36 "/usr/include/errno.h" 2 3 4
\r
4352 # 29 "../include/apr_errno.h" 2
\r
4353 # 44 "../include/apr_errno.h"
\r
4354 typedef int apr_status_t;
\r
4362 char * apr_strerror(apr_status_t statcode, char *buf,
\r
4363 apr_size_t bufsize);
\r
4364 # 45 "../include/apr_pools.h" 2
\r
4365 # 1 "../include/apr_general.h" 1
\r
4366 # 29 "../include/apr_general.h"
\r
4367 # 1 "../include/apr_pools.h" 1
\r
4368 # 30 "../include/apr_general.h" 2
\r
4369 # 68 "../include/apr_general.h"
\r
4370 typedef int apr_signum_t;
\r
4371 # 177 "../include/apr_general.h"
\r
4372 apr_status_t apr_initialize(void);
\r
4373 # 191 "../include/apr_general.h"
\r
4374 apr_status_t apr_app_initialize(int *argc,
\r
4375 char const * const * *argv,
\r
4376 char const * const * *env);
\r
4377 # 205 "../include/apr_general.h"
\r
4378 void apr_terminate(void);
\r
4379 # 216 "../include/apr_general.h"
\r
4380 void apr_terminate2(void);
\r
4381 # 233 "../include/apr_general.h"
\r
4382 apr_status_t apr_generate_random_bytes(unsigned char * buf,
\r
4383 apr_size_t length);
\r
4384 # 46 "../include/apr_pools.h" 2
\r
4386 # 1 "../include/apr_want.h" 1
\r
4387 # 48 "../include/apr_pools.h" 2
\r
4388 # 60 "../include/apr_pools.h"
\r
4389 typedef struct apr_pool_t apr_pool_t;
\r
4390 # 148 "../include/apr_pools.h"
\r
4391 typedef int (*apr_abortfunc_t)(int retcode);
\r
4392 # 164 "../include/apr_pools.h"
\r
4393 apr_status_t apr_pool_initialize(void);
\r
4401 void apr_pool_terminate(void);
\r
4409 # 1 "../include/apr_allocator.h" 1
\r
4410 # 28 "../include/apr_allocator.h"
\r
4411 # 1 "../include/apr_want.h" 1
\r
4412 # 29 "../include/apr_allocator.h" 2
\r
4413 # 41 "../include/apr_allocator.h"
\r
4414 typedef struct apr_allocator_t apr_allocator_t;
\r
4416 typedef struct apr_memnode_t apr_memnode_t;
\r
4417 # 54 "../include/apr_allocator.h"
\r
4418 struct apr_memnode_t {
\r
4419 apr_memnode_t *next;
\r
4420 apr_memnode_t **ref;
\r
4421 apr_uint32_t index;
\r
4422 apr_uint32_t free_index;
\r
4423 char *first_avail;
\r
4426 # 74 "../include/apr_allocator.h"
\r
4427 apr_status_t apr_allocator_create(apr_allocator_t **allocator)
\r
4428 __attribute__((nonnull(1)));
\r
4436 void apr_allocator_destroy(apr_allocator_t *allocator)
\r
4437 __attribute__((nonnull(1)));
\r
4445 apr_memnode_t * apr_allocator_alloc(apr_allocator_t *allocator,
\r
4447 __attribute__((nonnull(1)));
\r
4448 # 103 "../include/apr_allocator.h"
\r
4449 void apr_allocator_free(apr_allocator_t *allocator,
\r
4450 apr_memnode_t *memnode)
\r
4451 __attribute__((nonnull(1,2)));
\r
4454 # 1 "../include/apr_pools.h" 1
\r
4455 # 108 "../include/apr_allocator.h" 2
\r
4456 # 120 "../include/apr_allocator.h"
\r
4457 void apr_allocator_owner_set(apr_allocator_t *allocator,
\r
4459 __attribute__((nonnull(1)));
\r
4465 apr_pool_t * apr_allocator_owner_get(apr_allocator_t *allocator)
\r
4466 __attribute__((nonnull(1)));
\r
4474 void apr_allocator_max_free_set(apr_allocator_t *allocator,
\r
4476 __attribute__((nonnull(1)));
\r
4479 # 1 "../include/apr_thread_mutex.h" 1
\r
4480 # 41 "../include/apr_thread_mutex.h"
\r
4481 typedef struct apr_thread_mutex_t apr_thread_mutex_t;
\r
4489 # 1 "../include/apr_pools.h" 1
\r
4490 # 49 "../include/apr_thread_mutex.h" 2
\r
4491 # 65 "../include/apr_thread_mutex.h"
\r
4492 apr_status_t apr_thread_mutex_create(apr_thread_mutex_t **mutex,
\r
4493 unsigned int flags,
\r
4494 apr_pool_t *pool);
\r
4500 apr_status_t apr_thread_mutex_lock(apr_thread_mutex_t *mutex);
\r
4501 # 82 "../include/apr_thread_mutex.h"
\r
4502 apr_status_t apr_thread_mutex_trylock(apr_thread_mutex_t *mutex);
\r
4508 apr_status_t apr_thread_mutex_unlock(apr_thread_mutex_t *mutex);
\r
4514 apr_status_t apr_thread_mutex_destroy(apr_thread_mutex_t *mutex);
\r
4520 apr_pool_t * apr_thread_mutex_pool_get (const apr_thread_mutex_t *thethread_mutex);
\r
4521 # 142 "../include/apr_allocator.h" 2
\r
4529 void apr_allocator_mutex_set(apr_allocator_t *allocator,
\r
4530 apr_thread_mutex_t *mutex)
\r
4531 __attribute__((nonnull(1)));
\r
4537 apr_thread_mutex_t * apr_allocator_mutex_get(
\r
4538 apr_allocator_t *allocator)
\r
4539 __attribute__((nonnull(1)));
\r
4540 # 180 "../include/apr_pools.h" 2
\r
4541 # 196 "../include/apr_pools.h"
\r
4542 apr_status_t apr_pool_create_ex(apr_pool_t **newpool,
\r
4543 apr_pool_t *parent,
\r
4544 apr_abortfunc_t abort_fn,
\r
4545 apr_allocator_t *allocator)
\r
4546 __attribute__((nonnull(1)));
\r
4552 apr_status_t apr_pool_create_core_ex(apr_pool_t **newpool,
\r
4553 apr_abortfunc_t abort_fn,
\r
4554 apr_allocator_t *allocator);
\r
4555 # 226 "../include/apr_pools.h"
\r
4556 apr_status_t apr_pool_create_unmanaged_ex(apr_pool_t **newpool,
\r
4557 apr_abortfunc_t abort_fn,
\r
4558 apr_allocator_t *allocator)
\r
4559 __attribute__((nonnull(1)));
\r
4560 # 247 "../include/apr_pools.h"
\r
4561 apr_status_t apr_pool_create_ex_debug(apr_pool_t **newpool,
\r
4562 apr_pool_t *parent,
\r
4563 apr_abortfunc_t abort_fn,
\r
4564 apr_allocator_t *allocator,
\r
4565 const char *file_line)
\r
4566 __attribute__((nonnull(1)));
\r
4567 # 264 "../include/apr_pools.h"
\r
4568 apr_status_t apr_pool_create_core_ex_debug(apr_pool_t **newpool,
\r
4569 apr_abortfunc_t abort_fn,
\r
4570 apr_allocator_t *allocator,
\r
4571 const char *file_line);
\r
4572 # 284 "../include/apr_pools.h"
\r
4573 apr_status_t apr_pool_create_unmanaged_ex_debug(apr_pool_t **newpool,
\r
4574 apr_abortfunc_t abort_fn,
\r
4575 apr_allocator_t *allocator,
\r
4576 const char *file_line)
\r
4577 __attribute__((nonnull(1)));
\r
4578 # 354 "../include/apr_pools.h"
\r
4579 apr_allocator_t * apr_pool_allocator_get(apr_pool_t *pool)
\r
4580 __attribute__((nonnull(1)));
\r
4581 # 365 "../include/apr_pools.h"
\r
4582 void apr_pool_clear(apr_pool_t *p) __attribute__((nonnull(1)));
\r
4583 # 380 "../include/apr_pools.h"
\r
4584 void apr_pool_clear_debug(apr_pool_t *p,
\r
4585 const char *file_line)
\r
4586 __attribute__((nonnull(1)));
\r
4587 # 395 "../include/apr_pools.h"
\r
4588 void apr_pool_destroy(apr_pool_t *p) __attribute__((nonnull(1)));
\r
4589 # 410 "../include/apr_pools.h"
\r
4590 void apr_pool_destroy_debug(apr_pool_t *p,
\r
4591 const char *file_line)
\r
4592 __attribute__((nonnull(1)));
\r
4593 # 430 "../include/apr_pools.h"
\r
4594 void * apr_palloc(apr_pool_t *p, apr_size_t size)
\r
4598 __attribute__((nonnull(1)));
\r
4599 # 444 "../include/apr_pools.h"
\r
4600 void * apr_palloc_debug(apr_pool_t *p, apr_size_t size,
\r
4601 const char *file_line)
\r
4605 __attribute__((nonnull(1)));
\r
4606 # 476 "../include/apr_pools.h"
\r
4607 void * apr_pcalloc_debug(apr_pool_t *p, apr_size_t size,
\r
4608 const char *file_line)
\r
4609 __attribute__((nonnull(1)));
\r
4610 # 498 "../include/apr_pools.h"
\r
4611 void apr_pool_abort_set(apr_abortfunc_t abortfunc,
\r
4613 __attribute__((nonnull(2)));
\r
4620 apr_abortfunc_t apr_pool_abort_get(apr_pool_t *pool)
\r
4621 __attribute__((nonnull(1)));
\r
4628 apr_pool_t * apr_pool_parent_get(apr_pool_t *pool)
\r
4629 __attribute__((nonnull(1)));
\r
4630 # 529 "../include/apr_pools.h"
\r
4631 int apr_pool_is_ancestor(apr_pool_t *a, apr_pool_t *b);
\r
4638 void apr_pool_tag(apr_pool_t *pool, const char *tag)
\r
4639 __attribute__((nonnull(1)));
\r
4640 # 563 "../include/apr_pools.h"
\r
4641 apr_status_t apr_pool_userdata_set(const void *data,
\r
4643 apr_status_t (*cleanup)(void *),
\r
4645 __attribute__((nonnull(2,4)));
\r
4646 # 588 "../include/apr_pools.h"
\r
4647 apr_status_t apr_pool_userdata_setn(
\r
4648 const void *data, const char *key,
\r
4649 apr_status_t (*cleanup)(void *),
\r
4651 __attribute__((nonnull(2,4)));
\r
4659 apr_status_t apr_pool_userdata_get(void **data, const char *key,
\r
4661 __attribute__((nonnull(1,2,3)));
\r
4662 # 628 "../include/apr_pools.h"
\r
4663 void apr_pool_cleanup_register(
\r
4664 apr_pool_t *p, const void *data,
\r
4665 apr_status_t (*plain_cleanup)(void *),
\r
4666 apr_status_t (*child_cleanup)(void *))
\r
4667 __attribute__((nonnull(3,4)));
\r
4668 # 646 "../include/apr_pools.h"
\r
4669 void apr_pool_pre_cleanup_register(
\r
4670 apr_pool_t *p, const void *data,
\r
4671 apr_status_t (*plain_cleanup)(void *))
\r
4672 __attribute__((nonnull(3)));
\r
4673 # 663 "../include/apr_pools.h"
\r
4674 void apr_pool_cleanup_kill(apr_pool_t *p, const void *data,
\r
4675 apr_status_t (*cleanup)(void *))
\r
4676 __attribute__((nonnull(3)));
\r
4677 # 679 "../include/apr_pools.h"
\r
4678 void apr_pool_child_cleanup_set(
\r
4679 apr_pool_t *p, const void *data,
\r
4680 apr_status_t (*plain_cleanup)(void *),
\r
4681 apr_status_t (*child_cleanup)(void *))
\r
4682 __attribute__((nonnull(3,4)));
\r
4683 # 696 "../include/apr_pools.h"
\r
4684 apr_status_t apr_pool_cleanup_run(apr_pool_t *p, void *data,
\r
4685 apr_status_t (*cleanup)(void *))
\r
4686 __attribute__((nonnull(3)));
\r
4687 # 707 "../include/apr_pools.h"
\r
4688 apr_status_t apr_pool_cleanup_null(void *data);
\r
4696 void apr_pool_cleanup_for_exec(void);
\r
4697 # 18 "./../test/testutil.h" 2
\r
4699 # 1 "./../test/abts.h" 1
\r
4700 # 20 "./../test/testutil.h" 2
\r
4701 # 52 "./../test/testutil.h"
\r
4702 extern apr_pool_t *p;
\r
4706 void apr_assert_success(abts_case* tc, const char *context,
\r
4707 apr_status_t rv, int lineno);
\r
4711 void initialize(void);
\r
4713 abts_suite *testatomic(abts_suite *suite);
\r
4714 abts_suite *testdir(abts_suite *suite);
\r
4715 abts_suite *testdso(abts_suite *suite);
\r
4716 abts_suite *testdup(abts_suite *suite);
\r
4717 abts_suite *testescape(abts_suite *suite);
\r
4718 abts_suite *testenv(abts_suite *suite);
\r
4719 abts_suite *testfile(abts_suite *suite);
\r
4720 abts_suite *testfilecopy(abts_suite *suite);
\r
4721 abts_suite *testfileinfo(abts_suite *suite);
\r
4722 abts_suite *testflock(abts_suite *suite);
\r
4723 abts_suite *testfmt(abts_suite *suite);
\r
4724 abts_suite *testfnmatch(abts_suite *suite);
\r
4725 abts_suite *testgetopt(abts_suite *suite);
\r
4726 abts_suite *testglobalmutex(abts_suite *suite);
\r
4727 abts_suite *testhash(abts_suite *suite);
\r
4728 abts_suite *testipsub(abts_suite *suite);
\r
4729 abts_suite *testlock(abts_suite *suite);
\r
4730 abts_suite *testcond(abts_suite *suite);
\r
4731 abts_suite *testlfs(abts_suite *suite);
\r
4732 abts_suite *testmmap(abts_suite *suite);
\r
4733 abts_suite *testnames(abts_suite *suite);
\r
4734 abts_suite *testoc(abts_suite *suite);
\r
4735 abts_suite *testpath(abts_suite *suite);
\r
4736 abts_suite *testpipe(abts_suite *suite);
\r
4737 abts_suite *testpoll(abts_suite *suite);
\r
4738 abts_suite *testpool(abts_suite *suite);
\r
4739 abts_suite *testproc(abts_suite *suite);
\r
4740 abts_suite *testprocmutex(abts_suite *suite);
\r
4741 abts_suite *testrand(abts_suite *suite);
\r
4742 abts_suite *testsleep(abts_suite *suite);
\r
4743 abts_suite *testshm(abts_suite *suite);
\r
4744 abts_suite *testsock(abts_suite *suite);
\r
4745 abts_suite *testsockets(abts_suite *suite);
\r
4746 abts_suite *testsockopt(abts_suite *suite);
\r
4747 abts_suite *teststr(abts_suite *suite);
\r
4748 abts_suite *teststrnatcmp(abts_suite *suite);
\r
4749 abts_suite *testtable(abts_suite *suite);
\r
4750 abts_suite *testtemp(abts_suite *suite);
\r
4751 abts_suite *testthread(abts_suite *suite);
\r
4752 abts_suite *testtime(abts_suite *suite);
\r
4753 abts_suite *testud(abts_suite *suite);
\r
4754 abts_suite *testuser(abts_suite *suite);
\r
4755 abts_suite *testvsn(abts_suite *suite);
\r
4758 # 1 "./../test/testatomic.c" 1
\r
4759 # 17 "./../test/testatomic.c"
\r
4760 # 1 "./../test/testutil.h" 1
\r
4761 # 19 "./../test/testutil.h"
\r
4762 # 1 "./../test/abts.h" 1
\r
4763 # 20 "./../test/testutil.h" 2
\r
4764 # 18 "./../test/testatomic.c" 2
\r
4765 # 1 "../include/apr_strings.h" 1
\r
4766 # 52 "../include/apr_strings.h"
\r
4767 # 1 "../include/apr_want.h" 1
\r
4768 # 53 "../include/apr_strings.h" 2
\r
4769 # 76 "../include/apr_strings.h"
\r
4770 int apr_strnatcmp(char const *a, char const *b);
\r
4771 # 87 "../include/apr_strings.h"
\r
4772 int apr_strnatcasecmp(char const *a, char const *b);
\r
4780 char * apr_pstrdup(apr_pool_t *p, const char *s);
\r
4781 # 109 "../include/apr_strings.h"
\r
4782 char * apr_pstrmemdup(apr_pool_t *p, const char *s, apr_size_t n)
\r
4787 # 125 "../include/apr_strings.h"
\r
4788 char * apr_pstrndup(apr_pool_t *p, const char *s, apr_size_t n);
\r
4789 # 135 "../include/apr_strings.h"
\r
4790 void * apr_pmemdup(apr_pool_t *p, const void *m, apr_size_t n)
\r
4802 char * apr_pstrcat(apr_pool_t *p, ...)
\r
4804 __attribute__((sentinel))
\r
4807 # 161 "../include/apr_strings.h"
\r
4808 char * apr_pstrcatv(apr_pool_t *p, const struct iovec *vec,
\r
4809 apr_size_t nvec, apr_size_t *nbytes);
\r
4810 # 172 "../include/apr_strings.h"
\r
4811 char * apr_pvsprintf(apr_pool_t *p, const char *fmt, va_list ap);
\r
4812 # 182 "../include/apr_strings.h"
\r
4813 char * apr_psprintf(apr_pool_t *p, const char *fmt, ...)
\r
4814 __attribute__((format(printf,2,3)));
\r
4815 # 207 "../include/apr_strings.h"
\r
4816 char * apr_cpystrn(char *dst, const char *src,
\r
4817 apr_size_t dst_size);
\r
4818 # 217 "../include/apr_strings.h"
\r
4819 char * apr_collapse_spaces(char *dest, const char *src);
\r
4820 # 226 "../include/apr_strings.h"
\r
4821 apr_status_t apr_tokenize_to_argv(const char *arg_str,
\r
4823 apr_pool_t *token_context);
\r
4824 # 247 "../include/apr_strings.h"
\r
4825 char * apr_strtok(char *str, const char *sep, char **last);
\r
4826 # 279 "../include/apr_strings.h"
\r
4827 int apr_snprintf(char *buf, apr_size_t len,
\r
4828 const char *format, ...)
\r
4829 __attribute__((format(printf,3,4)));
\r
4830 # 291 "../include/apr_strings.h"
\r
4831 int apr_vsnprintf(char *buf, apr_size_t len, const char *format,
\r
4833 # 301 "../include/apr_strings.h"
\r
4834 char * apr_itoa(apr_pool_t *p, int n);
\r
4842 char * apr_ltoa(apr_pool_t *p, long n);
\r
4850 char * apr_off_t_toa(apr_pool_t *p, apr_off_t n);
\r
4851 # 335 "../include/apr_strings.h"
\r
4852 apr_status_t apr_strtoff(apr_off_t *offset, const char *buf,
\r
4853 char **end, int base);
\r
4854 # 353 "../include/apr_strings.h"
\r
4855 apr_int64_t apr_strtoi64(const char *buf, char **end, int base);
\r
4856 # 362 "../include/apr_strings.h"
\r
4857 apr_int64_t apr_atoi64(const char *buf);
\r
4858 # 372 "../include/apr_strings.h"
\r
4859 char * apr_strfsize(apr_off_t size, char *buf);
\r
4860 # 19 "./../test/testatomic.c" 2
\r
4861 # 1 "../include/apr_thread_proc.h" 1
\r
4862 # 26 "../include/apr_thread_proc.h"
\r
4863 # 1 "../include/apr_file_io.h" 1
\r
4864 # 27 "../include/apr_file_io.h"
\r
4865 # 1 "../include/apr_time.h" 1
\r
4866 # 40 "../include/apr_time.h"
\r
4867 extern const char apr_month_snames[12][4];
\r
4869 extern const char apr_day_snames[7][4];
\r
4873 typedef apr_int64_t apr_time_t;
\r
4874 # 56 "../include/apr_time.h"
\r
4875 typedef apr_int64_t apr_interval_time_t;
\r
4877 typedef apr_int32_t apr_short_interval_time_t;
\r
4878 # 88 "../include/apr_time.h"
\r
4879 apr_time_t apr_time_now(void);
\r
4882 typedef struct apr_time_exp_t apr_time_exp_t;
\r
4889 struct apr_time_exp_t {
\r
4891 apr_int32_t tm_usec;
\r
4893 apr_int32_t tm_sec;
\r
4895 apr_int32_t tm_min;
\r
4897 apr_int32_t tm_hour;
\r
4899 apr_int32_t tm_mday;
\r
4901 apr_int32_t tm_mon;
\r
4903 apr_int32_t tm_year;
\r
4905 apr_int32_t tm_wday;
\r
4907 apr_int32_t tm_yday;
\r
4909 apr_int32_t tm_isdst;
\r
4911 apr_int32_t tm_gmtoff;
\r
4919 apr_status_t apr_time_ansi_put(apr_time_t *result,
\r
4921 # 138 "../include/apr_time.h"
\r
4922 apr_status_t apr_time_exp_tz(apr_time_exp_t *result,
\r
4924 apr_int32_t offs);
\r
4931 apr_status_t apr_time_exp_gmt(apr_time_exp_t *result,
\r
4932 apr_time_t input);
\r
4939 apr_status_t apr_time_exp_lt(apr_time_exp_t *result,
\r
4940 apr_time_t input);
\r
4948 apr_status_t apr_time_exp_get(apr_time_t *result,
\r
4949 apr_time_exp_t *input);
\r
4957 apr_status_t apr_time_exp_gmt_get(apr_time_t *result,
\r
4958 apr_time_exp_t *input);
\r
4965 void apr_sleep(apr_interval_time_t t);
\r
4966 # 193 "../include/apr_time.h"
\r
4967 apr_status_t apr_rfc822_date(char *date_str, apr_time_t t);
\r
4968 # 207 "../include/apr_time.h"
\r
4969 apr_status_t apr_ctime(char *date_str, apr_time_t t);
\r
4970 # 217 "../include/apr_time.h"
\r
4971 apr_status_t apr_strftime(char *s, apr_size_t *retsize,
\r
4972 apr_size_t max, const char *format,
\r
4973 apr_time_exp_t *tm);
\r
4981 void apr_time_clock_hires(apr_pool_t *p);
\r
4982 # 28 "../include/apr_file_io.h" 2
\r
4984 # 1 "../include/apr_file_info.h" 1
\r
4985 # 26 "../include/apr_file_info.h"
\r
4986 # 1 "../include/apr_user.h" 1
\r
4987 # 45 "../include/apr_user.h"
\r
4988 typedef uid_t apr_uid_t;
\r
4989 # 54 "../include/apr_user.h"
\r
4990 typedef gid_t apr_gid_t;
\r
4991 # 66 "../include/apr_user.h"
\r
4992 apr_status_t apr_uid_current(apr_uid_t *userid,
\r
4993 apr_gid_t *groupid,
\r
4995 # 77 "../include/apr_user.h"
\r
4996 apr_status_t apr_uid_name_get(char **username, apr_uid_t userid,
\r
4998 # 88 "../include/apr_user.h"
\r
4999 apr_status_t apr_uid_get(apr_uid_t *userid, apr_gid_t *groupid,
\r
5000 const char *username, apr_pool_t *p);
\r
5001 # 98 "../include/apr_user.h"
\r
5002 apr_status_t apr_uid_homepath_get(char **dirname,
\r
5003 const char *username,
\r
5005 # 123 "../include/apr_user.h"
\r
5006 apr_status_t apr_gid_name_get(char **groupname,
\r
5007 apr_gid_t groupid, apr_pool_t *p);
\r
5008 # 133 "../include/apr_user.h"
\r
5009 apr_status_t apr_gid_get(apr_gid_t *groupid,
\r
5010 const char *groupname, apr_pool_t *p);
\r
5011 # 27 "../include/apr_file_info.h" 2
\r
5013 # 1 "../include/apr_tables.h" 1
\r
5014 # 56 "../include/apr_tables.h"
\r
5015 typedef struct apr_table_t apr_table_t;
\r
5018 typedef struct apr_array_header_t apr_array_header_t;
\r
5021 struct apr_array_header_t {
\r
5037 typedef struct apr_table_entry_t apr_table_entry_t;
\r
5040 struct apr_table_entry_t {
\r
5049 apr_uint32_t key_checksum;
\r
5057 const apr_array_header_t * apr_table_elts(const apr_table_t *t);
\r
5064 int apr_is_empty_table(const apr_table_t *t);
\r
5071 int apr_is_empty_array(const apr_array_header_t *a);
\r
5072 # 121 "../include/apr_tables.h"
\r
5073 apr_array_header_t * apr_array_make(apr_pool_t *p,
\r
5074 int nelts, int elt_size);
\r
5075 # 131 "../include/apr_tables.h"
\r
5076 void * apr_array_push(apr_array_header_t *arr);
\r
5077 # 158 "../include/apr_tables.h"
\r
5078 void * apr_array_pop(apr_array_header_t *arr);
\r
5086 void apr_array_clear(apr_array_header_t *arr);
\r
5094 void apr_array_cat(apr_array_header_t *dst,
\r
5095 const apr_array_header_t *src);
\r
5096 # 186 "../include/apr_tables.h"
\r
5097 apr_array_header_t * apr_array_copy(apr_pool_t *p,
\r
5098 const apr_array_header_t *arr);
\r
5099 # 196 "../include/apr_tables.h"
\r
5100 apr_array_header_t * apr_array_copy_hdr(apr_pool_t *p,
\r
5101 const apr_array_header_t *arr);
\r
5102 # 206 "../include/apr_tables.h"
\r
5103 apr_array_header_t * apr_array_append(apr_pool_t *p,
\r
5104 const apr_array_header_t *first,
\r
5105 const apr_array_header_t *second);
\r
5106 # 221 "../include/apr_tables.h"
\r
5107 char * apr_array_pstrcat(apr_pool_t *p,
\r
5108 const apr_array_header_t *arr,
\r
5110 # 232 "../include/apr_tables.h"
\r
5111 apr_table_t * apr_table_make(apr_pool_t *p, int nelts);
\r
5112 # 241 "../include/apr_tables.h"
\r
5113 apr_table_t * apr_table_copy(apr_pool_t *p,
\r
5114 const apr_table_t *t);
\r
5115 # 252 "../include/apr_tables.h"
\r
5116 apr_table_t * apr_table_clone(apr_pool_t *p,
\r
5117 const apr_table_t *t);
\r
5123 void apr_table_clear(apr_table_t *t);
\r
5124 # 268 "../include/apr_tables.h"
\r
5125 const char * apr_table_get(const apr_table_t *t, const char *key);
\r
5126 # 279 "../include/apr_tables.h"
\r
5127 const char * apr_table_getm(apr_pool_t *p, const apr_table_t *t,
\r
5129 # 291 "../include/apr_tables.h"
\r
5130 void apr_table_set(apr_table_t *t, const char *key,
\r
5132 # 304 "../include/apr_tables.h"
\r
5133 void apr_table_setn(apr_table_t *t, const char *key,
\r
5141 void apr_table_unset(apr_table_t *t, const char *key);
\r
5142 # 323 "../include/apr_tables.h"
\r
5143 void apr_table_merge(apr_table_t *t, const char *key,
\r
5145 # 335 "../include/apr_tables.h"
\r
5146 void apr_table_mergen(apr_table_t *t, const char *key,
\r
5148 # 347 "../include/apr_tables.h"
\r
5149 void apr_table_add(apr_table_t *t, const char *key,
\r
5151 # 360 "../include/apr_tables.h"
\r
5152 void apr_table_addn(apr_table_t *t, const char *key,
\r
5154 # 370 "../include/apr_tables.h"
\r
5155 apr_table_t * apr_table_overlay(apr_pool_t *p,
\r
5156 const apr_table_t *overlay,
\r
5157 const apr_table_t *base);
\r
5158 # 384 "../include/apr_tables.h"
\r
5159 typedef int (apr_table_do_callback_fn_t)(void *rec, const char *key,
\r
5160 const char *value);
\r
5161 # 406 "../include/apr_tables.h"
\r
5162 int apr_table_do(apr_table_do_callback_fn_t *comp,
\r
5163 void *rec, const apr_table_t *t, ...)
\r
5165 __attribute__((sentinel))
\r
5168 # 432 "../include/apr_tables.h"
\r
5169 int apr_table_vdo(apr_table_do_callback_fn_t *comp,
\r
5170 void *rec, const apr_table_t *t, va_list vp);
\r
5171 # 478 "../include/apr_tables.h"
\r
5172 void apr_table_overlap(apr_table_t *a, const apr_table_t *b,
\r
5174 # 491 "../include/apr_tables.h"
\r
5175 void apr_table_compress(apr_table_t *t, unsigned flags);
\r
5176 # 29 "../include/apr_file_info.h" 2
\r
5177 # 62 "../include/apr_file_info.h"
\r
5189 # 121 "../include/apr_file_info.h"
\r
5190 typedef struct apr_dir_t apr_dir_t;
\r
5194 typedef apr_int32_t apr_fileperms_t;
\r
5195 # 135 "../include/apr_file_info.h"
\r
5196 typedef dev_t apr_dev_t;
\r
5204 typedef struct apr_finfo_t apr_finfo_t;
\r
5205 # 174 "../include/apr_file_info.h"
\r
5206 struct apr_finfo_t {
\r
5211 apr_int32_t valid;
\r
5213 apr_fileperms_t protection;
\r
5218 apr_filetype_e filetype;
\r
5228 apr_int32_t nlink;
\r
5240 const char *fname;
\r
5244 struct apr_file_t *filehand;
\r
5246 # 229 "../include/apr_file_info.h"
\r
5247 apr_status_t apr_stat(apr_finfo_t *finfo, const char *fname,
\r
5248 apr_int32_t wanted, apr_pool_t *pool);
\r
5249 # 244 "../include/apr_file_info.h"
\r
5250 apr_status_t apr_dir_open(apr_dir_t **new_dir,
\r
5251 const char *dirname,
\r
5252 apr_pool_t *pool);
\r
5258 apr_status_t apr_dir_close(apr_dir_t *thedir);
\r
5259 # 267 "../include/apr_file_info.h"
\r
5260 apr_status_t apr_dir_read(apr_finfo_t *finfo, apr_int32_t wanted,
\r
5261 apr_dir_t *thedir);
\r
5267 apr_status_t apr_dir_rewind(apr_dir_t *thedir);
\r
5268 # 336 "../include/apr_file_info.h"
\r
5269 apr_status_t apr_filepath_root(const char **rootpath,
\r
5270 const char **filepath,
\r
5271 apr_int32_t flags,
\r
5273 # 354 "../include/apr_file_info.h"
\r
5274 apr_status_t apr_filepath_merge(char **newpath,
\r
5275 const char *rootpath,
\r
5276 const char *addpath,
\r
5277 apr_int32_t flags,
\r
5279 # 369 "../include/apr_file_info.h"
\r
5280 apr_status_t apr_filepath_list_split(apr_array_header_t **pathelts,
\r
5281 const char *liststr,
\r
5283 # 382 "../include/apr_file_info.h"
\r
5284 apr_status_t apr_filepath_list_merge(char **liststr,
\r
5285 apr_array_header_t *pathelts,
\r
5287 # 393 "../include/apr_file_info.h"
\r
5288 apr_status_t apr_filepath_get(char **path, apr_int32_t flags,
\r
5296 apr_status_t apr_filepath_set(const char *path, apr_pool_t *p);
\r
5297 # 419 "../include/apr_file_info.h"
\r
5298 apr_status_t apr_filepath_encoding(int *style, apr_pool_t *p);
\r
5299 # 30 "../include/apr_file_io.h" 2
\r
5300 # 1 "../include/apr_inherit.h" 1
\r
5301 # 31 "../include/apr_file_io.h" 2
\r
5305 # 1 "../include/apr_want.h" 1
\r
5306 # 35 "../include/apr_file_io.h" 2
\r
5307 # 180 "../include/apr_file_io.h"
\r
5308 typedef apr_uint32_t apr_fileattrs_t;
\r
5311 typedef int apr_seek_where_t;
\r
5316 typedef struct apr_file_t apr_file_t;
\r
5317 # 250 "../include/apr_file_io.h"
\r
5318 apr_status_t apr_file_open(apr_file_t **newf, const char *fname,
\r
5319 apr_int32_t flag, apr_fileperms_t perm,
\r
5320 apr_pool_t *pool);
\r
5326 apr_status_t apr_file_close(apr_file_t *file);
\r
5327 # 267 "../include/apr_file_io.h"
\r
5328 apr_status_t apr_file_remove(const char *path, apr_pool_t *pool);
\r
5329 # 278 "../include/apr_file_io.h"
\r
5330 apr_status_t apr_file_rename(const char *from_path,
\r
5331 const char *to_path,
\r
5332 apr_pool_t *pool);
\r
5340 apr_status_t apr_file_link(const char *from_path,
\r
5341 const char *to_path);
\r
5342 # 303 "../include/apr_file_io.h"
\r
5343 apr_status_t apr_file_copy(const char *from_path,
\r
5344 const char *to_path,
\r
5345 apr_fileperms_t perms,
\r
5346 apr_pool_t *pool);
\r
5347 # 319 "../include/apr_file_io.h"
\r
5348 apr_status_t apr_file_append(const char *from_path,
\r
5349 const char *to_path,
\r
5350 apr_fileperms_t perms,
\r
5351 apr_pool_t *pool);
\r
5358 apr_status_t apr_file_eof(apr_file_t *fptr);
\r
5359 # 346 "../include/apr_file_io.h"
\r
5360 apr_status_t apr_file_open_stderr(apr_file_t **thefile,
\r
5361 apr_pool_t *pool);
\r
5362 # 356 "../include/apr_file_io.h"
\r
5363 apr_status_t apr_file_open_stdout(apr_file_t **thefile,
\r
5364 apr_pool_t *pool);
\r
5365 # 366 "../include/apr_file_io.h"
\r
5366 apr_status_t apr_file_open_stdin(apr_file_t **thefile,
\r
5367 apr_pool_t *pool);
\r
5368 # 386 "../include/apr_file_io.h"
\r
5369 apr_status_t apr_file_open_flags_stderr(apr_file_t **thefile,
\r
5370 apr_int32_t flags,
\r
5371 apr_pool_t *pool);
\r
5372 # 407 "../include/apr_file_io.h"
\r
5373 apr_status_t apr_file_open_flags_stdout(apr_file_t **thefile,
\r
5374 apr_int32_t flags,
\r
5375 apr_pool_t *pool);
\r
5376 # 428 "../include/apr_file_io.h"
\r
5377 apr_status_t apr_file_open_flags_stdin(apr_file_t **thefile,
\r
5378 apr_int32_t flags,
\r
5379 apr_pool_t *pool);
\r
5380 # 449 "../include/apr_file_io.h"
\r
5381 apr_status_t apr_file_read(apr_file_t *thefile, void *buf,
\r
5382 apr_size_t *nbytes);
\r
5383 # 467 "../include/apr_file_io.h"
\r
5384 apr_status_t apr_file_write(apr_file_t *thefile, const void *buf,
\r
5385 apr_size_t *nbytes);
\r
5386 # 485 "../include/apr_file_io.h"
\r
5387 apr_status_t apr_file_writev(apr_file_t *thefile,
\r
5388 const struct iovec *vec,
\r
5389 apr_size_t nvec, apr_size_t *nbytes);
\r
5390 # 509 "../include/apr_file_io.h"
\r
5391 apr_status_t apr_file_read_full(apr_file_t *thefile, void *buf,
\r
5392 apr_size_t nbytes,
\r
5393 apr_size_t *bytes_read);
\r
5394 # 533 "../include/apr_file_io.h"
\r
5395 apr_status_t apr_file_write_full(apr_file_t *thefile,
\r
5397 apr_size_t nbytes,
\r
5398 apr_size_t *bytes_written);
\r
5399 # 552 "../include/apr_file_io.h"
\r
5400 apr_status_t apr_file_writev_full(apr_file_t *thefile,
\r
5401 const struct iovec *vec,
\r
5403 apr_size_t *nbytes);
\r
5409 apr_status_t apr_file_putc(char ch, apr_file_t *thefile);
\r
5416 apr_status_t apr_file_getc(char *ch, apr_file_t *thefile);
\r
5423 apr_status_t apr_file_ungetc(char ch, apr_file_t *thefile);
\r
5424 # 585 "../include/apr_file_io.h"
\r
5425 apr_status_t apr_file_gets(char *str, int len,
\r
5426 apr_file_t *thefile);
\r
5433 apr_status_t apr_file_puts(const char *str, apr_file_t *thefile);
\r
5439 apr_status_t apr_file_flush(apr_file_t *thefile);
\r
5445 apr_status_t apr_file_sync(apr_file_t *thefile);
\r
5451 apr_status_t apr_file_datasync(apr_file_t *thefile);
\r
5452 # 620 "../include/apr_file_io.h"
\r
5453 apr_status_t apr_file_dup(apr_file_t **new_file,
\r
5454 apr_file_t *old_file,
\r
5456 # 632 "../include/apr_file_io.h"
\r
5457 apr_status_t apr_file_dup2(apr_file_t *new_file,
\r
5458 apr_file_t *old_file,
\r
5460 # 647 "../include/apr_file_io.h"
\r
5461 apr_status_t apr_file_setaside(apr_file_t **new_file,
\r
5462 apr_file_t *old_file,
\r
5464 # 662 "../include/apr_file_io.h"
\r
5465 apr_status_t apr_file_buffer_set(apr_file_t *thefile,
\r
5467 apr_size_t bufsize);
\r
5473 apr_size_t apr_file_buffer_size_get(apr_file_t *thefile);
\r
5474 # 683 "../include/apr_file_io.h"
\r
5475 apr_status_t apr_file_seek(apr_file_t *thefile,
\r
5476 apr_seek_where_t where,
\r
5477 apr_off_t *offset);
\r
5478 # 700 "../include/apr_file_io.h"
\r
5479 apr_status_t apr_file_pipe_create(apr_file_t **in,
\r
5481 apr_pool_t *pool);
\r
5482 # 723 "../include/apr_file_io.h"
\r
5483 apr_status_t apr_file_pipe_create_ex(apr_file_t **in,
\r
5485 apr_int32_t blocking,
\r
5486 apr_pool_t *pool);
\r
5494 apr_status_t apr_file_namedpipe_create(const char *filename,
\r
5495 apr_fileperms_t perm,
\r
5496 apr_pool_t *pool);
\r
5503 apr_status_t apr_file_pipe_timeout_get(apr_file_t *thepipe,
\r
5504 apr_interval_time_t *timeout);
\r
5512 apr_status_t apr_file_pipe_timeout_set(apr_file_t *thepipe,
\r
5513 apr_interval_time_t timeout);
\r
5514 # 766 "../include/apr_file_io.h"
\r
5515 apr_status_t apr_file_lock(apr_file_t *thefile, int type);
\r
5521 apr_status_t apr_file_unlock(apr_file_t *thefile);
\r
5522 # 781 "../include/apr_file_io.h"
\r
5523 apr_status_t apr_file_name_get(const char **new_path,
\r
5524 apr_file_t *thefile);
\r
5532 apr_status_t apr_file_data_get(void **data, const char *key,
\r
5533 apr_file_t *file);
\r
5534 # 800 "../include/apr_file_io.h"
\r
5535 apr_status_t apr_file_data_set(apr_file_t *file, void *data,
\r
5537 apr_status_t (*cleanup)(void *));
\r
5538 # 811 "../include/apr_file_io.h"
\r
5539 int apr_file_printf(apr_file_t *fptr,
\r
5540 const char *format, ...)
\r
5541 __attribute__((format(printf,2,3)));
\r
5542 # 827 "../include/apr_file_io.h"
\r
5543 apr_status_t apr_file_perms_set(const char *fname,
\r
5544 apr_fileperms_t perms);
\r
5545 # 846 "../include/apr_file_io.h"
\r
5546 apr_status_t apr_file_attrs_set(const char *fname,
\r
5547 apr_fileattrs_t attributes,
\r
5548 apr_fileattrs_t attr_mask,
\r
5549 apr_pool_t *pool);
\r
5550 # 859 "../include/apr_file_io.h"
\r
5551 apr_status_t apr_file_mtime_set(const char *fname,
\r
5553 apr_pool_t *pool);
\r
5561 apr_status_t apr_dir_make(const char *path, apr_fileperms_t perm,
\r
5562 apr_pool_t *pool);
\r
5563 # 879 "../include/apr_file_io.h"
\r
5564 apr_status_t apr_dir_make_recursive(const char *path,
\r
5565 apr_fileperms_t perm,
\r
5566 apr_pool_t *pool);
\r
5567 # 890 "../include/apr_file_io.h"
\r
5568 apr_status_t apr_dir_remove(const char *path, apr_pool_t *pool);
\r
5576 apr_status_t apr_file_info_get(apr_finfo_t *finfo,
\r
5577 apr_int32_t wanted,
\r
5578 apr_file_t *thefile);
\r
5579 # 909 "../include/apr_file_io.h"
\r
5580 apr_status_t apr_file_trunc(apr_file_t *fp, apr_off_t offset);
\r
5587 apr_int32_t apr_file_flags_get(apr_file_t *f);
\r
5592 apr_pool_t * apr_file_pool_get (const apr_file_t *thefile);
\r
5598 apr_status_t apr_file_inherit_set( apr_file_t *thefile);
\r
5603 apr_status_t apr_file_inherit_unset( apr_file_t *thefile);
\r
5604 # 951 "../include/apr_file_io.h"
\r
5605 apr_status_t apr_file_mktemp(apr_file_t **fp, char *templ,
\r
5606 apr_int32_t flags, apr_pool_t *p);
\r
5607 # 964 "../include/apr_file_io.h"
\r
5608 apr_status_t apr_temp_dir_get(const char **temp_dir,
\r
5610 # 27 "../include/apr_thread_proc.h" 2
\r
5615 # 1 "/usr/include/x86_64-linux-gnu/sys/time.h" 1 3 4
\r
5616 # 25 "/usr/include/x86_64-linux-gnu/sys/time.h" 3 4
\r
5617 # 1 "/usr/include/time.h" 1 3 4
\r
5618 # 26 "/usr/include/x86_64-linux-gnu/sys/time.h" 2 3 4
\r
5620 # 1 "/usr/include/x86_64-linux-gnu/bits/time.h" 1 3 4
\r
5621 # 28 "/usr/include/x86_64-linux-gnu/sys/time.h" 2 3 4
\r
5622 # 55 "/usr/include/x86_64-linux-gnu/sys/time.h" 3 4
\r
5625 int tz_minuteswest;
\r
5629 typedef struct timezone *__restrict __timezone_ptr_t;
\r
5630 # 71 "/usr/include/x86_64-linux-gnu/sys/time.h" 3 4
\r
5631 extern int gettimeofday (struct timeval *__restrict __tv,
\r
5632 __timezone_ptr_t __tz) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
5637 extern int settimeofday (const struct timeval *__tv,
\r
5638 const struct timezone *__tz)
\r
5639 __attribute__ ((__nothrow__ ));
\r
5645 extern int adjtime (const struct timeval *__delta,
\r
5646 struct timeval *__olddelta) __attribute__ ((__nothrow__ ));
\r
5651 enum __itimer_which
\r
5657 ITIMER_VIRTUAL = 1,
\r
5670 struct timeval it_interval;
\r
5672 struct timeval it_value;
\r
5680 typedef int __itimer_which_t;
\r
5685 extern int getitimer (__itimer_which_t __which,
\r
5686 struct itimerval *__value) __attribute__ ((__nothrow__ ));
\r
5691 extern int setitimer (__itimer_which_t __which,
\r
5692 const struct itimerval *__restrict __new,
\r
5693 struct itimerval *__restrict __old) __attribute__ ((__nothrow__ ));
\r
5698 extern int utimes (const char *__file, const struct timeval __tvp[2])
\r
5699 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
5703 extern int lutimes (const char *__file, const struct timeval __tvp[2])
\r
5704 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
5707 extern int futimes (int __fd, const struct timeval __tvp[2]) __attribute__ ((__nothrow__ ));
\r
5708 # 32 "../include/apr_thread_proc.h" 2
\r
5709 # 1 "/usr/include/x86_64-linux-gnu/sys/resource.h" 1 3 4
\r
5710 # 24 "/usr/include/x86_64-linux-gnu/sys/resource.h" 3 4
\r
5711 # 1 "/usr/include/x86_64-linux-gnu/bits/resource.h" 1 3 4
\r
5712 # 31 "/usr/include/x86_64-linux-gnu/bits/resource.h" 3 4
\r
5713 enum __rlimit_resource
\r
5743 RLIMIT_NOFILE = 7,
\r
5744 __RLIMIT_OFILE = RLIMIT_NOFILE,
\r
5753 __RLIMIT_NPROC = 6,
\r
5757 __RLIMIT_MEMLOCK = 8,
\r
5761 __RLIMIT_LOCKS = 10,
\r
5765 __RLIMIT_SIGPENDING = 11,
\r
5769 __RLIMIT_MSGQUEUE = 12,
\r
5775 __RLIMIT_NICE = 13,
\r
5780 __RLIMIT_RTPRIO = 14,
\r
5786 __RLIMIT_RTTIME = 15,
\r
5789 __RLIMIT_NLIMITS = 16,
\r
5790 __RLIM_NLIMITS = __RLIMIT_NLIMITS
\r
5794 # 131 "/usr/include/x86_64-linux-gnu/bits/resource.h" 3 4
\r
5795 typedef __rlim_t rlim_t;
\r
5810 # 158 "/usr/include/x86_64-linux-gnu/bits/resource.h" 3 4
\r
5818 RUSAGE_CHILDREN = -1
\r
5819 # 176 "/usr/include/x86_64-linux-gnu/bits/resource.h" 3 4
\r
5824 # 1 "/usr/include/x86_64-linux-gnu/bits/time.h" 1 3 4
\r
5825 # 180 "/usr/include/x86_64-linux-gnu/bits/resource.h" 2 3 4
\r
5836 struct timeval ru_utime;
\r
5838 struct timeval ru_stime;
\r
5840 __extension__ union
\r
5842 long int ru_maxrss;
\r
5843 __syscall_slong_t __ru_maxrss_word;
\r
5848 __extension__ union
\r
5850 long int ru_ixrss;
\r
5851 __syscall_slong_t __ru_ixrss_word;
\r
5854 __extension__ union
\r
5856 long int ru_idrss;
\r
5857 __syscall_slong_t __ru_idrss_word;
\r
5860 __extension__ union
\r
5862 long int ru_isrss;
\r
5863 __syscall_slong_t __ru_isrss_word;
\r
5867 __extension__ union
\r
5869 long int ru_minflt;
\r
5870 __syscall_slong_t __ru_minflt_word;
\r
5873 __extension__ union
\r
5875 long int ru_majflt;
\r
5876 __syscall_slong_t __ru_majflt_word;
\r
5879 __extension__ union
\r
5881 long int ru_nswap;
\r
5882 __syscall_slong_t __ru_nswap_word;
\r
5886 __extension__ union
\r
5888 long int ru_inblock;
\r
5889 __syscall_slong_t __ru_inblock_word;
\r
5892 __extension__ union
\r
5894 long int ru_oublock;
\r
5895 __syscall_slong_t __ru_oublock_word;
\r
5898 __extension__ union
\r
5900 long int ru_msgsnd;
\r
5901 __syscall_slong_t __ru_msgsnd_word;
\r
5904 __extension__ union
\r
5906 long int ru_msgrcv;
\r
5907 __syscall_slong_t __ru_msgrcv_word;
\r
5910 __extension__ union
\r
5912 long int ru_nsignals;
\r
5913 __syscall_slong_t __ru_nsignals_word;
\r
5918 __extension__ union
\r
5920 long int ru_nvcsw;
\r
5921 __syscall_slong_t __ru_nvcsw_word;
\r
5925 __extension__ union
\r
5927 long int ru_nivcsw;
\r
5928 __syscall_slong_t __ru_nivcsw_word;
\r
5938 enum __priority_which
\r
5947 # 25 "/usr/include/x86_64-linux-gnu/sys/resource.h" 2 3 4
\r
5948 # 42 "/usr/include/x86_64-linux-gnu/sys/resource.h" 3 4
\r
5949 typedef int __rlimit_resource_t;
\r
5950 typedef int __rusage_who_t;
\r
5951 typedef int __priority_which_t;
\r
5957 extern int getrlimit (__rlimit_resource_t __resource,
\r
5958 struct rlimit *__rlimits) __attribute__ ((__nothrow__ ));
\r
5959 # 69 "/usr/include/x86_64-linux-gnu/sys/resource.h" 3 4
\r
5960 extern int setrlimit (__rlimit_resource_t __resource,
\r
5961 const struct rlimit *__rlimits) __attribute__ ((__nothrow__ ));
\r
5962 # 87 "/usr/include/x86_64-linux-gnu/sys/resource.h" 3 4
\r
5963 extern int getrusage (__rusage_who_t __who, struct rusage *__usage) __attribute__ ((__nothrow__ ));
\r
5969 extern int getpriority (__priority_which_t __which, id_t __who) __attribute__ ((__nothrow__ ));
\r
5973 extern int setpriority (__priority_which_t __which, id_t __who, int __prio)
\r
5974 __attribute__ ((__nothrow__ ));
\r
5975 # 33 "../include/apr_thread_proc.h" 2
\r
5976 # 45 "../include/apr_thread_proc.h"
\r
5998 APR_PROC_EXIT = 1,
\r
5999 APR_PROC_SIGNAL = 2,
\r
6000 APR_PROC_SIGNAL_CORE = 4
\r
6002 # 133 "../include/apr_thread_proc.h"
\r
6003 typedef struct apr_proc_t {
\r
6012 # 161 "../include/apr_thread_proc.h"
\r
6014 # 173 "../include/apr_thread_proc.h"
\r
6015 typedef void (apr_child_errfn_t)(apr_pool_t *proc, apr_status_t err,
\r
6016 const char *description);
\r
6019 typedef struct apr_thread_t apr_thread_t;
\r
6022 typedef struct apr_threadattr_t apr_threadattr_t;
\r
6025 typedef struct apr_procattr_t apr_procattr_t;
\r
6028 typedef struct apr_thread_once_t apr_thread_once_t;
\r
6031 typedef struct apr_threadkey_t apr_threadkey_t;
\r
6034 typedef struct apr_other_child_rec_t apr_other_child_rec_t;
\r
6039 typedef void *( *apr_thread_start_t)(apr_thread_t*, void*);
\r
6046 APR_KILL_AFTER_TIMEOUT,
\r
6048 APR_KILL_ONLY_ONCE
\r
6049 } apr_kill_conditions_e;
\r
6050 # 218 "../include/apr_thread_proc.h"
\r
6051 apr_status_t apr_threadattr_create(apr_threadattr_t **new_attr,
\r
6052 apr_pool_t *cont);
\r
6059 apr_status_t apr_threadattr_detach_set(apr_threadattr_t *attr,
\r
6068 apr_status_t apr_threadattr_detach_get(apr_threadattr_t *attr);
\r
6075 apr_status_t apr_threadattr_stacksize_set(apr_threadattr_t *attr,
\r
6076 apr_size_t stacksize);
\r
6077 # 255 "../include/apr_thread_proc.h"
\r
6078 apr_status_t apr_threadattr_guardsize_set(apr_threadattr_t *attr,
\r
6079 apr_size_t guardsize);
\r
6080 # 266 "../include/apr_thread_proc.h"
\r
6081 apr_status_t apr_thread_create(apr_thread_t **new_thread,
\r
6082 apr_threadattr_t *attr,
\r
6083 apr_thread_start_t func,
\r
6084 void *data, apr_pool_t *cont);
\r
6091 apr_status_t apr_thread_exit(apr_thread_t *thd,
\r
6092 apr_status_t retval);
\r
6099 apr_status_t apr_thread_join(apr_status_t *retval,
\r
6100 apr_thread_t *thd);
\r
6105 void apr_thread_yield(void);
\r
6113 apr_status_t apr_thread_once_init(apr_thread_once_t **control,
\r
6115 # 310 "../include/apr_thread_proc.h"
\r
6116 apr_status_t apr_thread_once(apr_thread_once_t *control,
\r
6117 void (*func)(void));
\r
6123 apr_status_t apr_thread_detach(apr_thread_t *thd);
\r
6131 apr_status_t apr_thread_data_get(void **data, const char *key,
\r
6132 apr_thread_t *thread);
\r
6133 # 335 "../include/apr_thread_proc.h"
\r
6134 apr_status_t apr_thread_data_set(void *data, const char *key,
\r
6135 apr_status_t (*cleanup) (void *),
\r
6136 apr_thread_t *thread);
\r
6144 apr_status_t apr_threadkey_private_create(apr_threadkey_t **key,
\r
6145 void (*dest)(void *),
\r
6146 apr_pool_t *cont);
\r
6153 apr_status_t apr_threadkey_private_get(void **new_mem,
\r
6154 apr_threadkey_t *key);
\r
6161 apr_status_t apr_threadkey_private_set(void *priv,
\r
6162 apr_threadkey_t *key);
\r
6168 apr_status_t apr_threadkey_private_delete(apr_threadkey_t *key);
\r
6176 apr_status_t apr_threadkey_data_get(void **data, const char *key,
\r
6177 apr_threadkey_t *threadkey);
\r
6178 # 387 "../include/apr_thread_proc.h"
\r
6179 apr_status_t apr_threadkey_data_set(void *data, const char *key,
\r
6180 apr_status_t (*cleanup) (void *),
\r
6181 apr_threadkey_t *threadkey);
\r
6182 # 398 "../include/apr_thread_proc.h"
\r
6183 apr_status_t apr_procattr_create(apr_procattr_t **new_attr,
\r
6184 apr_pool_t *cont);
\r
6185 # 415 "../include/apr_thread_proc.h"
\r
6186 apr_status_t apr_procattr_io_set(apr_procattr_t *attr,
\r
6187 apr_int32_t in, apr_int32_t out,
\r
6189 # 434 "../include/apr_thread_proc.h"
\r
6190 apr_status_t apr_procattr_child_in_set(struct apr_procattr_t *attr,
\r
6191 apr_file_t *child_in,
\r
6192 apr_file_t *parent_in);
\r
6193 # 451 "../include/apr_thread_proc.h"
\r
6194 apr_status_t apr_procattr_child_out_set(struct apr_procattr_t *attr,
\r
6195 apr_file_t *child_out,
\r
6196 apr_file_t *parent_out);
\r
6197 # 468 "../include/apr_thread_proc.h"
\r
6198 apr_status_t apr_procattr_child_err_set(struct apr_procattr_t *attr,
\r
6199 apr_file_t *child_err,
\r
6200 apr_file_t *parent_err);
\r
6201 # 479 "../include/apr_thread_proc.h"
\r
6202 apr_status_t apr_procattr_dir_set(apr_procattr_t *attr,
\r
6204 # 493 "../include/apr_thread_proc.h"
\r
6205 apr_status_t apr_procattr_cmdtype_set(apr_procattr_t *attr,
\r
6206 apr_cmdtype_e cmd);
\r
6213 apr_status_t apr_procattr_detach_set(apr_procattr_t *attr,
\r
6214 apr_int32_t detach);
\r
6215 # 517 "../include/apr_thread_proc.h"
\r
6216 apr_status_t apr_procattr_limit_set(apr_procattr_t *attr,
\r
6218 struct rlimit *limit);
\r
6219 # 533 "../include/apr_thread_proc.h"
\r
6220 apr_status_t apr_procattr_child_errfn_set(apr_procattr_t *attr,
\r
6221 apr_child_errfn_t *errfn);
\r
6222 # 548 "../include/apr_thread_proc.h"
\r
6223 apr_status_t apr_procattr_error_check_set(apr_procattr_t *attr,
\r
6225 # 558 "../include/apr_thread_proc.h"
\r
6226 apr_status_t apr_procattr_addrspace_set(apr_procattr_t *attr,
\r
6227 apr_int32_t addrspace);
\r
6228 # 569 "../include/apr_thread_proc.h"
\r
6229 apr_status_t apr_procattr_user_set(apr_procattr_t *attr,
\r
6230 const char *username,
\r
6231 const char *password);
\r
6238 apr_status_t apr_procattr_group_set(apr_procattr_t *attr,
\r
6239 const char *groupname);
\r
6240 # 591 "../include/apr_thread_proc.h"
\r
6241 apr_status_t apr_proc_fork(apr_proc_t *proc, apr_pool_t *cont);
\r
6242 # 610 "../include/apr_thread_proc.h"
\r
6243 apr_status_t apr_proc_create(apr_proc_t *new_proc,
\r
6244 const char *progname,
\r
6245 const char * const *args,
\r
6246 const char * const *env,
\r
6247 apr_procattr_t *attr,
\r
6248 apr_pool_t *pool);
\r
6249 # 643 "../include/apr_thread_proc.h"
\r
6250 apr_status_t apr_proc_wait(apr_proc_t *proc,
\r
6251 int *exitcode, apr_exit_why_e *exitwhy,
\r
6252 apr_wait_how_e waithow);
\r
6253 # 673 "../include/apr_thread_proc.h"
\r
6254 apr_status_t apr_proc_wait_all_procs(apr_proc_t *proc,
\r
6256 apr_exit_why_e *exitwhy,
\r
6257 apr_wait_how_e waithow,
\r
6259 # 688 "../include/apr_thread_proc.h"
\r
6260 apr_status_t apr_proc_detach(int daemonize);
\r
6261 # 707 "../include/apr_thread_proc.h"
\r
6262 void apr_proc_other_child_register(apr_proc_t *proc,
\r
6263 void (*maintenance) (int reason,
\r
6266 void *data, apr_file_t *write_fd,
\r
6268 # 723 "../include/apr_thread_proc.h"
\r
6269 void apr_proc_other_child_unregister(void *data);
\r
6270 # 745 "../include/apr_thread_proc.h"
\r
6271 apr_status_t apr_proc_other_child_alert(apr_proc_t *proc,
\r
6274 # 756 "../include/apr_thread_proc.h"
\r
6275 void apr_proc_other_child_refresh(apr_other_child_rec_t *ocr,
\r
6284 void apr_proc_other_child_refresh_all(int reason);
\r
6291 apr_status_t apr_proc_kill(apr_proc_t *proc, int sig);
\r
6292 # 787 "../include/apr_thread_proc.h"
\r
6293 void apr_pool_note_subprocess(apr_pool_t *a, apr_proc_t *proc,
\r
6294 apr_kill_conditions_e how);
\r
6295 # 798 "../include/apr_thread_proc.h"
\r
6296 apr_status_t apr_setup_signal_thread(void);
\r
6297 # 807 "../include/apr_thread_proc.h"
\r
6298 apr_status_t apr_signal_thread(int(*signal_handler)(int signum));
\r
6306 apr_pool_t * apr_thread_pool_get (const apr_thread_t *thethread);
\r
6307 # 20 "./../test/testatomic.c" 2
\r
6310 # 1 "../include/apr_atomic.h" 1
\r
6311 # 47 "../include/apr_atomic.h"
\r
6312 apr_status_t apr_atomic_init(apr_pool_t *p);
\r
6313 # 59 "../include/apr_atomic.h"
\r
6314 apr_uint32_t apr_atomic_read32(volatile apr_uint32_t *mem);
\r
6321 void apr_atomic_set32(volatile apr_uint32_t *mem, apr_uint32_t val);
\r
6329 apr_uint32_t apr_atomic_add32(volatile apr_uint32_t *mem, apr_uint32_t val);
\r
6336 void apr_atomic_sub32(volatile apr_uint32_t *mem, apr_uint32_t val);
\r
6343 apr_uint32_t apr_atomic_inc32(volatile apr_uint32_t *mem);
\r
6350 int apr_atomic_dec32(volatile apr_uint32_t *mem);
\r
6351 # 105 "../include/apr_atomic.h"
\r
6352 apr_uint32_t apr_atomic_cas32(volatile apr_uint32_t *mem, apr_uint32_t with,
\r
6353 apr_uint32_t cmp);
\r
6361 apr_uint32_t apr_atomic_xchg32(volatile apr_uint32_t *mem, apr_uint32_t val);
\r
6362 # 124 "../include/apr_atomic.h"
\r
6363 void* apr_atomic_casptr(volatile void **mem, void *with, const void *cmp);
\r
6371 void* apr_atomic_xchgptr(volatile void **mem, void *with);
\r
6372 # 23 "./../test/testatomic.c" 2
\r
6373 # 37 "./../test/testatomic.c"
\r
6374 static void test_init(abts_case *tc, void *data)
\r
6376 apr_assert_success(tc, "Could not initliaze atomics", apr_atomic_init(p), 39);
\r
6379 static void test_set32(abts_case *tc, void *data)
\r
6382 apr_atomic_set32(&y32, 2);
\r
6383 abts_int_equal(tc, 2, y32, 46);
\r
6386 static void test_read32(abts_case *tc, void *data)
\r
6389 apr_atomic_set32(&y32, 2);
\r
6390 abts_int_equal(tc, 2, apr_atomic_read32(&y32), 53);
\r
6393 static void test_dec32(abts_case *tc, void *data)
\r
6398 apr_atomic_set32(&y32, 2);
\r
6400 rv = apr_atomic_dec32(&y32);
\r
6401 abts_int_equal(tc, 1, y32, 64);
\r
6402 abts_assert(tc, "atomic_dec returned zero when it shouldn't", rv != 0, 65);;
\r
6404 rv = apr_atomic_dec32(&y32);
\r
6405 abts_int_equal(tc, 0, y32, 68);
\r
6406 abts_assert(tc, "atomic_dec didn't returned zero when it should", rv == 0, 69);;
\r
6409 static void test_xchg32(abts_case *tc, void *data)
\r
6411 apr_uint32_t oldval;
\r
6414 apr_atomic_set32(&y32, 100);
\r
6415 oldval = apr_atomic_xchg32(&y32, 50);
\r
6417 abts_int_equal(tc, 100, oldval, 80);
\r
6418 abts_int_equal(tc, 50, y32, 81);
\r
6421 static void test_xchgptr(abts_case *tc, void *data)
\r
6424 void *ref = "little piggy";
\r
6425 volatile void *target_ptr = ref;
\r
6428 old_ptr = apr_atomic_xchgptr(&target_ptr, &a);
\r
6429 abts_ptr_equal(tc, ref, old_ptr, 92);
\r
6430 abts_ptr_equal(tc, &a, (void *) target_ptr, 93);
\r
6433 static void test_cas_equal(abts_case *tc, void *data)
\r
6435 apr_uint32_t casval = 0;
\r
6436 apr_uint32_t oldval;
\r
6438 oldval = apr_atomic_cas32(&casval, 12, 0);
\r
6439 abts_int_equal(tc, 0, oldval, 102);
\r
6440 abts_int_equal(tc, 12, casval, 103);
\r
6443 static void test_cas_equal_nonnull(abts_case *tc, void *data)
\r
6445 apr_uint32_t casval = 12;
\r
6446 apr_uint32_t oldval;
\r
6448 oldval = apr_atomic_cas32(&casval, 23, 12);
\r
6449 abts_int_equal(tc, 12, oldval, 112);
\r
6450 abts_int_equal(tc, 23, casval, 113);
\r
6453 static void test_cas_notequal(abts_case *tc, void *data)
\r
6455 apr_uint32_t casval = 12;
\r
6456 apr_uint32_t oldval;
\r
6458 oldval = apr_atomic_cas32(&casval, 23, 2);
\r
6459 abts_int_equal(tc, 12, oldval, 122);
\r
6460 abts_int_equal(tc, 12, casval, 123);
\r
6463 static void test_casptr_equal(abts_case *tc, void *data)
\r
6466 volatile void *target_ptr = ((void*)0);
\r
6469 old_ptr = apr_atomic_casptr(&target_ptr, &a, ((void*)0));
\r
6470 abts_ptr_equal(tc, ((void*)0), old_ptr, 133);
\r
6471 abts_ptr_equal(tc, &a, (void *) target_ptr, 134);
\r
6474 static void test_casptr_equal_nonnull(abts_case *tc, void *data)
\r
6477 volatile void *target_ptr = &a;
\r
6480 old_ptr = apr_atomic_casptr(&target_ptr, &b, &a);
\r
6481 abts_ptr_equal(tc, &a, old_ptr, 144);
\r
6482 abts_ptr_equal(tc, &b, (void *) target_ptr, 145);
\r
6485 static void test_casptr_notequal(abts_case *tc, void *data)
\r
6488 volatile void *target_ptr = &a;
\r
6491 old_ptr = apr_atomic_casptr(&target_ptr, &a, &b);
\r
6492 abts_ptr_equal(tc, &a, old_ptr, 155);
\r
6493 abts_ptr_equal(tc, &a, (void *) target_ptr, 156);
\r
6496 static void test_add32(abts_case *tc, void *data)
\r
6498 apr_uint32_t oldval;
\r
6501 apr_atomic_set32(&y32, 23);
\r
6502 oldval = apr_atomic_add32(&y32, 4);
\r
6503 abts_int_equal(tc, 23, oldval, 166);
\r
6504 abts_int_equal(tc, 27, y32, 167);
\r
6507 static void test_add32_neg(abts_case *tc, void *data)
\r
6509 apr_uint32_t oldval;
\r
6512 apr_atomic_set32(&y32, 23);
\r
6513 oldval = apr_atomic_add32(&y32, -10);
\r
6514 abts_int_equal(tc, 23, oldval, 177);
\r
6515 abts_int_equal(tc, 13, y32, 178);
\r
6518 static void test_inc32(abts_case *tc, void *data)
\r
6520 apr_uint32_t oldval;
\r
6523 apr_atomic_set32(&y32, 23);
\r
6524 oldval = apr_atomic_inc32(&y32);
\r
6525 abts_int_equal(tc, 23, oldval, 188);
\r
6526 abts_int_equal(tc, 24, y32, 189);
\r
6529 static void test_set_add_inc_sub(abts_case *tc, void *data)
\r
6533 apr_atomic_set32(&y32, 0);
\r
6534 apr_atomic_add32(&y32, 20);
\r
6535 apr_atomic_inc32(&y32);
\r
6536 apr_atomic_sub32(&y32, 10);
\r
6538 abts_int_equal(tc, 11, y32, 201);
\r
6541 static void test_wrap_zero(abts_case *tc, void *data)
\r
6545 apr_uint32_t minus1 = -1;
\r
6548 apr_atomic_set32(&y32, 0);
\r
6549 rv = apr_atomic_dec32(&y32);
\r
6551 abts_assert(tc, "apr_atomic_dec32 on zero returned zero.", rv != 0, 214);;
\r
6552 str = apr_psprintf(p, "zero wrap failed: 0 - 1 = %d", y32);
\r
6553 abts_assert(tc, str, y32 == minus1, 216);;
\r
6556 static void test_inc_neg1(abts_case *tc, void *data)
\r
6558 apr_uint32_t y32 = -1;
\r
6559 apr_uint32_t minus1 = -1;
\r
6563 rv = apr_atomic_inc32(&y32);
\r
6565 abts_assert(tc, "apr_atomic_inc32 didn't return the old value.", rv == minus1, 228);;
\r
6566 str = apr_psprintf(p, "zero wrap failed: -1 + 1 = %d", y32);
\r
6567 abts_assert(tc, str, y32 == 0, 230);;
\r
6573 void * thread_func_mutex(apr_thread_t *thd, void *data);
\r
6574 void * thread_func_atomic(apr_thread_t *thd, void *data);
\r
6576 apr_thread_mutex_t *thread_lock;
\r
6577 volatile apr_uint32_t mutex_locks = 0;
\r
6578 volatile apr_uint32_t atomic_ops = 0;
\r
6579 apr_status_t exit_ret_val = 123;
\r
6581 void * thread_func_mutex(apr_thread_t *thd, void *data)
\r
6585 for (i = 0; i < 1; i++) {
\r
6586 apr_thread_mutex_lock(thread_lock);
\r
6588 apr_thread_mutex_unlock(thread_lock);
\r
6590 apr_thread_exit(thd, exit_ret_val);
\r
6591 return ((void*)0);
\r
6594 void * thread_func_atomic(apr_thread_t *thd, void *data)
\r
6598 for (i = 0; i < 1 ; i++) {
\r
6599 apr_atomic_inc32(&atomic_ops);
\r
6600 apr_atomic_add32(&atomic_ops, 2);
\r
6601 apr_atomic_dec32(&atomic_ops);
\r
6602 apr_atomic_dec32(&atomic_ops);
\r
6604 apr_thread_exit(thd, exit_ret_val);
\r
6605 return ((void*)0);
\r
6608 static void test_atomics_threaded(abts_case *tc, void *data)
\r
6610 apr_thread_t *t1[2];
\r
6611 apr_thread_t *t2[2];
\r
6619 rv = apr_thread_mutex_create(&thread_lock, 0x0, p);
\r
6620 apr_assert_success(tc, "Could not create lock", rv, 283);
\r
6622 for (i = 0; i < 2; i++) {
\r
6623 apr_status_t r1, r2;
\r
6624 r1 = apr_thread_create(&t1[i], ((void*)0), thread_func_mutex, ((void*)0), p);
\r
6625 r2 = apr_thread_create(&t2[i], ((void*)0), thread_func_atomic, ((void*)0), p);
\r
6626 abts_assert(tc, "Failed creating threads", !r1 && !r2, 289);;
\r
6629 for (i = 0; i < 2; i++) {
\r
6630 apr_status_t s1, s2;
\r
6631 apr_thread_join(&s1, t1[i]);
\r
6632 apr_thread_join(&s2, t2[i]);
\r
6634 abts_assert(tc, "Invalid return value from thread_join", s1 == exit_ret_val && s2 == exit_ret_val, 298);;
\r
6638 abts_int_equal(tc, 2 * 1, mutex_locks, 301);
\r
6639 abts_int_equal(tc, 2 * 1, apr_atomic_read32(&atomic_ops), 303);
\r
6642 rv = apr_thread_mutex_destroy(thread_lock);
\r
6643 abts_assert(tc, "Failed creating threads", rv == 0, 306);;
\r
6646 typedef struct tbox_t tbox_t;
\r
6650 apr_uint32_t *mem;
\r
6651 apr_uint32_t preval;
\r
6652 apr_uint32_t postval;
\r
6653 apr_uint32_t loop;
\r
6654 void (*func)(tbox_t *box);
\r
6657 static __inline__ void busyloop_read32(tbox_t *tbox)
\r
6662 val = apr_atomic_read32(tbox->mem);
\r
6664 if (val != tbox->preval)
\r
6665 apr_thread_yield();
\r
6671 static void busyloop_set32(tbox_t *tbox)
\r
6674 busyloop_read32(tbox);
\r
6675 apr_atomic_set32(tbox->mem, tbox->postval);
\r
6676 } while (--tbox->loop);
\r
6679 static void busyloop_add32(tbox_t *tbox)
\r
6684 busyloop_read32(tbox);
\r
6685 val = apr_atomic_add32(tbox->mem, tbox->postval);
\r
6686 apr_thread_mutex_lock(thread_lock);
\r
6687 abts_int_equal(tbox->tc, val, tbox->preval, 350);
\r
6688 apr_thread_mutex_unlock(thread_lock);
\r
6689 } while (--tbox->loop);
\r
6692 static void busyloop_sub32(tbox_t *tbox)
\r
6695 busyloop_read32(tbox);
\r
6696 apr_atomic_sub32(tbox->mem, tbox->postval);
\r
6697 } while (--tbox->loop);
\r
6700 static void busyloop_inc32(tbox_t *tbox)
\r
6705 busyloop_read32(tbox);
\r
6706 val = apr_atomic_inc32(tbox->mem);
\r
6707 apr_thread_mutex_lock(thread_lock);
\r
6708 abts_int_equal(tbox->tc, val, tbox->preval, 371);
\r
6709 apr_thread_mutex_unlock(thread_lock);
\r
6710 } while (--tbox->loop);
\r
6713 static void busyloop_dec32(tbox_t *tbox)
\r
6718 busyloop_read32(tbox);
\r
6719 val = apr_atomic_dec32(tbox->mem);
\r
6720 apr_thread_mutex_lock(thread_lock);
\r
6721 abts_int_nequal(tbox->tc, 0, val, 384);
\r
6722 apr_thread_mutex_unlock(thread_lock);
\r
6723 } while (--tbox->loop);
\r
6726 static void busyloop_cas32(tbox_t *tbox)
\r
6732 val = apr_atomic_cas32(tbox->mem, tbox->postval, tbox->preval);
\r
6734 if (val != tbox->preval)
\r
6735 apr_thread_yield();
\r
6739 } while (--tbox->loop);
\r
6742 static void busyloop_xchg32(tbox_t *tbox)
\r
6747 busyloop_read32(tbox);
\r
6748 val = apr_atomic_xchg32(tbox->mem, tbox->postval);
\r
6749 apr_thread_mutex_lock(thread_lock);
\r
6750 abts_int_equal(tbox->tc, val, tbox->preval, 413);
\r
6751 apr_thread_mutex_unlock(thread_lock);
\r
6752 } while (--tbox->loop);
\r
6755 static void * thread_func_busyloop(apr_thread_t *thd, void *data)
\r
6757 tbox_t *tbox = data;
\r
6761 apr_thread_exit(thd, 0);
\r
6763 return ((void*)0);
\r
6766 static void test_atomics_busyloop_threaded(abts_case *tc, void *data)
\r
6770 apr_uint32_t count = 0;
\r
6772 apr_thread_t *thread[2];
\r
6774 rv = apr_thread_mutex_create(&thread_lock, 0x0, p);
\r
6775 apr_assert_success(tc, "Could not create lock", rv, 438);
\r
6778 for (i = 0; i < 2; i++) {
\r
6780 tbox[i].mem = &count;
\r
6781 tbox[i].loop = 50;
\r
6784 tbox[0].preval = 98;
\r
6785 tbox[0].postval = 3891;
\r
6786 tbox[0].func = busyloop_add32;
\r
6788 tbox[1].preval = 3989;
\r
6789 tbox[1].postval = 1010;
\r
6790 tbox[1].func = busyloop_sub32;
\r
6792 tbox[2].preval = 2979;
\r
6793 tbox[2].postval = 0;
\r
6794 tbox[2].func = busyloop_inc32;
\r
6796 tbox[3].preval = 2980;
\r
6797 tbox[3].postval = 16384;
\r
6798 tbox[3].func = busyloop_set32;
\r
6800 tbox[4].preval = 16384;
\r
6801 tbox[4].postval = 0;
\r
6802 tbox[4].func = busyloop_dec32;
\r
6804 tbox[5].preval = 16383;
\r
6805 tbox[5].postval = 1048576;
\r
6806 tbox[5].func = busyloop_cas32;
\r
6808 tbox[6].preval = 1048576;
\r
6809 tbox[6].postval = 98;
\r
6810 tbox[6].func = busyloop_xchg32;
\r
6813 for (i = 0; i < 2; i++) {
\r
6814 rv = apr_thread_create(&thread[i], ((void*)0), thread_func_busyloop,
\r
6816 abts_assert(tc, "Failed creating thread", rv == 0, 479);;
\r
6820 apr_atomic_set32(tbox->mem, 98);
\r
6822 for (i = 0; i < 2; i++) {
\r
6823 apr_status_t retval;
\r
6824 rv = apr_thread_join(&retval, thread[i]);
\r
6825 abts_assert(tc, "Thread join failed", rv == 0, 488);;
\r
6826 abts_assert(tc, "Invalid return value from thread_join", retval == 0, 489);;
\r
6829 abts_int_equal(tbox->tc, 98, count, 492);
\r
6831 rv = apr_thread_mutex_destroy(thread_lock);
\r
6832 abts_assert(tc, "Failed creating threads", rv == 0, 495);;
\r
6837 abts_suite *testatomic(abts_suite *suite)
\r
6839 suite = abts_add_suite(suite, "./../test/testatomic.c");
\r
6841 abts_run_test(suite, test_init, ((void*)0));
\r
6842 abts_run_test(suite, test_set32, ((void*)0));
\r
6843 abts_run_test(suite, test_read32, ((void*)0));
\r
6844 abts_run_test(suite, test_dec32, ((void*)0));
\r
6845 abts_run_test(suite, test_xchg32, ((void*)0));
\r
6846 abts_run_test(suite, test_xchgptr, ((void*)0));
\r
6847 abts_run_test(suite, test_cas_equal, ((void*)0));
\r
6848 abts_run_test(suite, test_cas_equal_nonnull, ((void*)0));
\r
6849 abts_run_test(suite, test_cas_notequal, ((void*)0));
\r
6850 abts_run_test(suite, test_casptr_equal, ((void*)0));
\r
6851 abts_run_test(suite, test_casptr_equal_nonnull, ((void*)0));
\r
6852 abts_run_test(suite, test_casptr_notequal, ((void*)0));
\r
6853 abts_run_test(suite, test_add32, ((void*)0));
\r
6854 abts_run_test(suite, test_add32_neg, ((void*)0));
\r
6855 abts_run_test(suite, test_inc32, ((void*)0));
\r
6856 abts_run_test(suite, test_set_add_inc_sub, ((void*)0));
\r
6857 abts_run_test(suite, test_wrap_zero, ((void*)0));
\r
6858 abts_run_test(suite, test_inc_neg1, ((void*)0));
\r
6861 abts_run_test(suite, test_atomics_threaded, ((void*)0));
\r
6862 abts_run_test(suite, test_atomics_busyloop_threaded, ((void*)0));
\r
6868 # 1 "./../test/testutil.c" 1
\r
6869 # 20 "./../test/testutil.c"
\r
6870 # 1 "./../test/abts.h" 1
\r
6871 # 21 "./../test/testutil.c" 2
\r
6872 # 1 "./../test/testutil.h" 1
\r
6873 # 19 "./../test/testutil.h"
\r
6874 # 1 "./../test/abts.h" 1
\r
6875 # 20 "./../test/testutil.h" 2
\r
6876 # 22 "./../test/testutil.c" 2
\r
6881 void apr_assert_success(abts_case* tc, const char* context, apr_status_t rv,
\r
6884 if (rv == ((20000 + 50000) + 23)) {
\r
6885 abts_not_impl(tc, context, lineno);
\r
6886 } else if (rv != 0) {
\r
6887 char buf[8096], ebuf[128];
\r
6888 sprintf(buf, "%s (%d): %s\n", context, rv,
\r
6889 apr_strerror(rv, ebuf, sizeof ebuf));
\r
6890 abts_fail(tc, buf, lineno);
\r
6894 void initialize(void) {
\r
6896 atexit(apr_terminate);
\r
6898 apr_pool_create_ex(&p, ((void*)0), ((void*)0), ((void*)0));
\r
6901 # 1 "./../locks/unix/thread_mutex.c" 1
\r
6902 # 17 "./../locks/unix/thread_mutex.c"
\r
6903 # 1 "../include/arch/unix/apr_arch_thread_mutex.h" 1
\r
6904 # 21 "../include/arch/unix/apr_arch_thread_mutex.h"
\r
6905 # 1 "../include/arch/unix/apr_private.h" 1
\r
6906 # 999 "../include/arch/unix/apr_private.h"
\r
6907 # 1 "../include/arch/unix/../apr_private_common.h" 1
\r
6908 # 27 "../include/arch/unix/../apr_private_common.h"
\r
6909 apr_status_t apr_filepath_list_split_impl(apr_array_header_t **pathelts,
\r
6910 const char *liststr,
\r
6914 apr_status_t apr_filepath_list_merge_impl(char **liststr,
\r
6915 apr_array_header_t *pathelts,
\r
6918 # 1000 "../include/arch/unix/apr_private.h" 2
\r
6919 # 22 "../include/arch/unix/apr_arch_thread_mutex.h" 2
\r
6922 # 1 "../include/apr_portable.h" 1
\r
6923 # 32 "../include/apr_portable.h"
\r
6924 # 1 "../include/apr_network_io.h" 1
\r
6925 # 31 "../include/apr_network_io.h"
\r
6926 # 1 "/usr/include/netinet/in.h" 1 3 4
\r
6927 # 22 "/usr/include/netinet/in.h" 3 4
\r
6928 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stdint.h" 1 3 4
\r
6929 # 23 "/usr/include/netinet/in.h" 2 3 4
\r
6937 typedef uint32_t in_addr_t;
\r
6945 # 1 "/usr/include/x86_64-linux-gnu/bits/in.h" 1 3 4
\r
6946 # 112 "/usr/include/x86_64-linux-gnu/bits/in.h" 3 4
\r
6949 struct in_addr ip_dst;
\r
6956 struct in_addr imr_multiaddr;
\r
6957 struct in_addr imr_address;
\r
6965 struct in_addr ipi_spec_dst;
\r
6966 struct in_addr ipi_addr;
\r
6968 # 38 "/usr/include/netinet/in.h" 2 3 4
\r
6993 IPPROTO_DCCP = 33,
\r
6995 IPPROTO_IPV6 = 41,
\r
6997 IPPROTO_RSVP = 46,
\r
7007 IPPROTO_BEETPH = 94,
\r
7009 IPPROTO_ENCAP = 98,
\r
7011 IPPROTO_PIM = 103,
\r
7013 IPPROTO_COMP = 108,
\r
7015 IPPROTO_SCTP = 132,
\r
7017 IPPROTO_UDPLITE = 136,
\r
7019 IPPROTO_RAW = 255,
\r
7030 IPPROTO_HOPOPTS = 0,
\r
7032 IPPROTO_ROUTING = 43,
\r
7034 IPPROTO_FRAGMENT = 44,
\r
7036 IPPROTO_ICMPV6 = 58,
\r
7038 IPPROTO_NONE = 59,
\r
7040 IPPROTO_DSTOPTS = 60,
\r
7048 typedef uint16_t in_port_t;
\r
7054 IPPORT_DISCARD = 9,
\r
7055 IPPORT_SYSTAT = 11,
\r
7056 IPPORT_DAYTIME = 13,
\r
7057 IPPORT_NETSTAT = 15,
\r
7059 IPPORT_TELNET = 23,
\r
7061 IPPORT_TIMESERVER = 37,
\r
7062 IPPORT_NAMESERVER = 42,
\r
7063 IPPORT_WHOIS = 43,
\r
7068 IPPORT_FINGER = 79,
\r
7069 IPPORT_TTYLINK = 87,
\r
7070 IPPORT_SUPDUP = 95,
\r
7073 IPPORT_EXECSERVER = 512,
\r
7074 IPPORT_LOGINSERVER = 513,
\r
7075 IPPORT_CMDSERVER = 514,
\r
7076 IPPORT_EFSSERVER = 520,
\r
7079 IPPORT_BIFFUDP = 512,
\r
7080 IPPORT_WHOSERVER = 513,
\r
7081 IPPORT_ROUTESERVER = 520,
\r
7084 IPPORT_RESERVED = 1024,
\r
7087 IPPORT_USERRESERVED = 5000
\r
7089 # 209 "/usr/include/netinet/in.h" 3 4
\r
7094 uint8_t __u6_addr8[16];
\r
7096 uint16_t __u6_addr16[8];
\r
7097 uint32_t __u6_addr32[4];
\r
7108 extern const struct in6_addr in6addr_any;
\r
7109 extern const struct in6_addr in6addr_loopback;
\r
7110 # 237 "/usr/include/netinet/in.h" 3 4
\r
7111 struct sockaddr_in
\r
7113 sa_family_t sin_family;
\r
7114 in_port_t sin_port;
\r
7115 struct in_addr sin_addr;
\r
7118 unsigned char sin_zero[sizeof (struct sockaddr) -
\r
7119 (sizeof (unsigned short int)) -
\r
7120 sizeof (in_port_t) -
\r
7121 sizeof (struct in_addr)];
\r
7126 struct sockaddr_in6
\r
7128 sa_family_t sin6_family;
\r
7129 in_port_t sin6_port;
\r
7130 uint32_t sin6_flowinfo;
\r
7131 struct in6_addr sin6_addr;
\r
7132 uint32_t sin6_scope_id;
\r
7141 struct in_addr imr_multiaddr;
\r
7144 struct in_addr imr_interface;
\r
7147 struct ip_mreq_source
\r
7150 struct in_addr imr_multiaddr;
\r
7153 struct in_addr imr_interface;
\r
7156 struct in_addr imr_sourceaddr;
\r
7165 struct in6_addr ipv6mr_multiaddr;
\r
7168 unsigned int ipv6mr_interface;
\r
7177 uint32_t gr_interface;
\r
7180 struct sockaddr_storage gr_group;
\r
7183 struct group_source_req
\r
7186 uint32_t gsr_interface;
\r
7189 struct sockaddr_storage gsr_group;
\r
7192 struct sockaddr_storage gsr_source;
\r
7197 struct ip_msfilter
\r
7200 struct in_addr imsf_multiaddr;
\r
7203 struct in_addr imsf_interface;
\r
7206 uint32_t imsf_fmode;
\r
7209 uint32_t imsf_numsrc;
\r
7211 struct in_addr imsf_slist[1];
\r
7218 struct group_filter
\r
7221 uint32_t gf_interface;
\r
7224 struct sockaddr_storage gf_group;
\r
7227 uint32_t gf_fmode;
\r
7230 uint32_t gf_numsrc;
\r
7232 struct sockaddr_storage gf_slist[1];
\r
7234 # 374 "/usr/include/netinet/in.h" 3 4
\r
7235 extern uint32_t ntohl (uint32_t __netlong) __attribute__ ((__nothrow__ )) __attribute__ ((__const__));
\r
7236 extern uint16_t ntohs (uint16_t __netshort)
\r
7237 __attribute__ ((__nothrow__ )) __attribute__ ((__const__));
\r
7238 extern uint32_t htonl (uint32_t __hostlong)
\r
7239 __attribute__ ((__nothrow__ )) __attribute__ ((__const__));
\r
7240 extern uint16_t htons (uint16_t __hostshort)
\r
7241 __attribute__ ((__nothrow__ )) __attribute__ ((__const__));
\r
7247 # 1 "/usr/include/x86_64-linux-gnu/bits/byteswap.h" 1 3 4
\r
7248 # 386 "/usr/include/netinet/in.h" 2 3 4
\r
7249 # 501 "/usr/include/netinet/in.h" 3 4
\r
7250 extern int bindresvport (int __sockfd, struct sockaddr_in *__sock_in) __attribute__ ((__nothrow__ ));
\r
7253 extern int bindresvport6 (int __sockfd, struct sockaddr_in6 *__sock_in)
\r
7254 __attribute__ ((__nothrow__ ));
\r
7255 # 32 "../include/apr_network_io.h" 2
\r
7256 # 108 "../include/apr_network_io.h"
\r
7258 APR_SHUTDOWN_READ,
\r
7259 APR_SHUTDOWN_WRITE,
\r
7260 APR_SHUTDOWN_READWRITE
\r
7261 } apr_shutdown_how_e;
\r
7262 # 172 "../include/apr_network_io.h"
\r
7266 } apr_interface_e;
\r
7267 # 193 "../include/apr_network_io.h"
\r
7268 typedef struct apr_socket_t apr_socket_t;
\r
7272 typedef struct apr_hdtr_t apr_hdtr_t;
\r
7274 typedef struct in_addr apr_in_addr_t;
\r
7276 typedef struct apr_ipsubnet_t apr_ipsubnet_t;
\r
7279 typedef apr_uint16_t apr_port_t;
\r
7284 typedef struct apr_sockaddr_t apr_sockaddr_t;
\r
7288 struct apr_sockaddr_t {
\r
7298 apr_int32_t family;
\r
7300 apr_socklen_t salen;
\r
7311 apr_sockaddr_t *next;
\r
7315 struct sockaddr_in sin;
\r
7318 struct sockaddr_in6 sin6;
\r
7323 struct sockaddr_storage sas;
\r
7327 # 263 "../include/apr_network_io.h"
\r
7328 struct apr_hdtr_t {
\r
7330 struct iovec* headers;
\r
7334 struct iovec* trailers;
\r
7338 # 287 "../include/apr_network_io.h"
\r
7339 apr_status_t apr_socket_create(apr_socket_t **new_sock,
\r
7340 int family, int type,
\r
7342 apr_pool_t *cont);
\r
7343 # 305 "../include/apr_network_io.h"
\r
7344 apr_status_t apr_socket_shutdown(apr_socket_t *thesocket,
\r
7345 apr_shutdown_how_e how);
\r
7351 apr_status_t apr_socket_close(apr_socket_t *thesocket);
\r
7352 # 321 "../include/apr_network_io.h"
\r
7353 apr_status_t apr_socket_bind(apr_socket_t *sock,
\r
7354 apr_sockaddr_t *sa);
\r
7355 # 331 "../include/apr_network_io.h"
\r
7356 apr_status_t apr_socket_listen(apr_socket_t *sock,
\r
7357 apr_int32_t backlog);
\r
7358 # 345 "../include/apr_network_io.h"
\r
7359 apr_status_t apr_socket_accept(apr_socket_t **new_sock,
\r
7360 apr_socket_t *sock,
\r
7361 apr_pool_t *connection_pool);
\r
7369 apr_status_t apr_socket_connect(apr_socket_t *sock,
\r
7370 apr_sockaddr_t *sa);
\r
7371 # 370 "../include/apr_network_io.h"
\r
7372 apr_status_t apr_socket_atreadeof(apr_socket_t *sock,
\r
7374 # 396 "../include/apr_network_io.h"
\r
7375 apr_status_t apr_sockaddr_info_get(apr_sockaddr_t **sa,
\r
7376 const char *hostname,
\r
7377 apr_int32_t family,
\r
7379 apr_int32_t flags,
\r
7381 # 411 "../include/apr_network_io.h"
\r
7382 apr_status_t apr_getnameinfo(char **hostname,
\r
7383 apr_sockaddr_t *sa,
\r
7384 apr_int32_t flags);
\r
7385 # 445 "../include/apr_network_io.h"
\r
7386 apr_status_t apr_parse_addr_port(char **addr,
\r
7391 # 459 "../include/apr_network_io.h"
\r
7392 apr_status_t apr_gethostname(char *buf, int len, apr_pool_t *cont);
\r
7400 apr_status_t apr_socket_data_get(void **data, const char *key,
\r
7401 apr_socket_t *sock);
\r
7402 # 477 "../include/apr_network_io.h"
\r
7403 apr_status_t apr_socket_data_set(apr_socket_t *sock, void *data,
\r
7405 apr_status_t (*cleanup)(void*));
\r
7406 # 498 "../include/apr_network_io.h"
\r
7407 apr_status_t apr_socket_send(apr_socket_t *sock, const char *buf,
\r
7409 # 519 "../include/apr_network_io.h"
\r
7410 apr_status_t apr_socket_sendv(apr_socket_t *sock,
\r
7411 const struct iovec *vec,
\r
7412 apr_int32_t nvec, apr_size_t *len);
\r
7413 # 530 "../include/apr_network_io.h"
\r
7414 apr_status_t apr_socket_sendto(apr_socket_t *sock,
\r
7415 apr_sockaddr_t *where,
\r
7416 apr_int32_t flags, const char *buf,
\r
7418 # 548 "../include/apr_network_io.h"
\r
7419 apr_status_t apr_socket_recvfrom(apr_sockaddr_t *from,
\r
7420 apr_socket_t *sock,
\r
7421 apr_int32_t flags, char *buf,
\r
7423 # 573 "../include/apr_network_io.h"
\r
7424 apr_status_t apr_socket_sendfile(apr_socket_t *sock,
\r
7427 apr_off_t *offset,
\r
7429 apr_int32_t flags);
\r
7430 # 601 "../include/apr_network_io.h"
\r
7431 apr_status_t apr_socket_recv(apr_socket_t *sock,
\r
7432 char *buf, apr_size_t *len);
\r
7433 # 626 "../include/apr_network_io.h"
\r
7434 apr_status_t apr_socket_opt_set(apr_socket_t *sock,
\r
7435 apr_int32_t opt, apr_int32_t on);
\r
7436 # 640 "../include/apr_network_io.h"
\r
7437 apr_status_t apr_socket_timeout_set(apr_socket_t *sock,
\r
7438 apr_interval_time_t t);
\r
7439 # 662 "../include/apr_network_io.h"
\r
7440 apr_status_t apr_socket_opt_get(apr_socket_t *sock,
\r
7441 apr_int32_t opt, apr_int32_t *on);
\r
7448 apr_status_t apr_socket_timeout_get(apr_socket_t *sock,
\r
7449 apr_interval_time_t *t);
\r
7457 apr_status_t apr_socket_atmark(apr_socket_t *sock,
\r
7459 # 690 "../include/apr_network_io.h"
\r
7460 apr_status_t apr_socket_addr_get(apr_sockaddr_t **sa,
\r
7461 apr_interface_e which,
\r
7462 apr_socket_t *sock);
\r
7463 # 701 "../include/apr_network_io.h"
\r
7464 apr_status_t apr_sockaddr_ip_get(char **addr,
\r
7465 apr_sockaddr_t *sockaddr);
\r
7472 apr_status_t apr_sockaddr_ip_getbuf(char *buf, apr_size_t buflen,
\r
7473 apr_sockaddr_t *sockaddr);
\r
7474 # 722 "../include/apr_network_io.h"
\r
7475 int apr_sockaddr_equal(const apr_sockaddr_t *addr1,
\r
7476 const apr_sockaddr_t *addr2);
\r
7477 # 733 "../include/apr_network_io.h"
\r
7478 int apr_sockaddr_is_wildcard(const apr_sockaddr_t *addr);
\r
7485 apr_status_t apr_socket_type_get(apr_socket_t *sock,
\r
7493 apr_status_t apr_getservbyname(apr_sockaddr_t *sockaddr,
\r
7494 const char *servname);
\r
7495 # 758 "../include/apr_network_io.h"
\r
7496 apr_status_t apr_ipsubnet_create(apr_ipsubnet_t **ipsub,
\r
7497 const char *ipstr,
\r
7498 const char *mask_or_numbits,
\r
7500 # 770 "../include/apr_network_io.h"
\r
7501 int apr_ipsubnet_test(apr_ipsubnet_t *ipsub, apr_sockaddr_t *sa);
\r
7502 # 791 "../include/apr_network_io.h"
\r
7503 apr_status_t apr_socket_protocol_get(apr_socket_t *sock,
\r
7509 apr_pool_t * apr_socket_pool_get (const apr_socket_t *thesocket);
\r
7514 apr_status_t apr_socket_inherit_set( apr_socket_t *thesocket);
\r
7519 apr_status_t apr_socket_inherit_unset( apr_socket_t *thesocket);
\r
7520 # 823 "../include/apr_network_io.h"
\r
7521 apr_status_t apr_mcast_join(apr_socket_t *sock,
\r
7522 apr_sockaddr_t *join,
\r
7523 apr_sockaddr_t *iface,
\r
7524 apr_sockaddr_t *source);
\r
7525 # 838 "../include/apr_network_io.h"
\r
7526 apr_status_t apr_mcast_leave(apr_socket_t *sock,
\r
7527 apr_sockaddr_t *addr,
\r
7528 apr_sockaddr_t *iface,
\r
7529 apr_sockaddr_t *source);
\r
7530 # 850 "../include/apr_network_io.h"
\r
7531 apr_status_t apr_mcast_hops(apr_socket_t *sock,
\r
7539 apr_status_t apr_mcast_loopback(apr_socket_t *sock,
\r
7548 apr_status_t apr_mcast_interface(apr_socket_t *sock,
\r
7549 apr_sockaddr_t *iface);
\r
7550 # 33 "../include/apr_portable.h" 2
\r
7552 # 1 "../include/apr_global_mutex.h" 1
\r
7553 # 26 "../include/apr_global_mutex.h"
\r
7554 # 1 "../include/apr_proc_mutex.h" 1
\r
7555 # 44 "../include/apr_proc_mutex.h"
\r
7560 APR_LOCK_PROC_PTHREAD,
\r
7561 APR_LOCK_POSIXSEM,
\r
7566 typedef struct apr_proc_mutex_t apr_proc_mutex_t;
\r
7567 # 79 "../include/apr_proc_mutex.h"
\r
7568 apr_status_t apr_proc_mutex_create(apr_proc_mutex_t **mutex,
\r
7569 const char *fname,
\r
7570 apr_lockmech_e mech,
\r
7571 apr_pool_t *pool);
\r
7572 # 95 "../include/apr_proc_mutex.h"
\r
7573 apr_status_t apr_proc_mutex_child_init(apr_proc_mutex_t **mutex,
\r
7574 const char *fname,
\r
7575 apr_pool_t *pool);
\r
7582 apr_status_t apr_proc_mutex_lock(apr_proc_mutex_t *mutex);
\r
7583 # 113 "../include/apr_proc_mutex.h"
\r
7584 apr_status_t apr_proc_mutex_trylock(apr_proc_mutex_t *mutex);
\r
7590 apr_status_t apr_proc_mutex_unlock(apr_proc_mutex_t *mutex);
\r
7596 apr_status_t apr_proc_mutex_destroy(apr_proc_mutex_t *mutex);
\r
7604 apr_status_t apr_proc_mutex_cleanup(void *mutex);
\r
7611 const char * apr_proc_mutex_lockfile(apr_proc_mutex_t *mutex);
\r
7618 const char * apr_proc_mutex_name(apr_proc_mutex_t *mutex);
\r
7623 const char * apr_proc_mutex_defname(void);
\r
7629 apr_pool_t * apr_proc_mutex_pool_get (const apr_proc_mutex_t *theproc_mutex);
\r
7630 # 27 "../include/apr_global_mutex.h" 2
\r
7631 # 46 "../include/apr_global_mutex.h"
\r
7632 typedef struct apr_global_mutex_t apr_global_mutex_t;
\r
7633 # 74 "../include/apr_global_mutex.h"
\r
7634 apr_status_t apr_global_mutex_create(apr_global_mutex_t **mutex,
\r
7635 const char *fname,
\r
7636 apr_lockmech_e mech,
\r
7637 apr_pool_t *pool);
\r
7638 # 90 "../include/apr_global_mutex.h"
\r
7639 apr_status_t apr_global_mutex_child_init(
\r
7640 apr_global_mutex_t **mutex,
\r
7641 const char *fname,
\r
7642 apr_pool_t *pool);
\r
7649 apr_status_t apr_global_mutex_lock(apr_global_mutex_t *mutex);
\r
7650 # 109 "../include/apr_global_mutex.h"
\r
7651 apr_status_t apr_global_mutex_trylock(apr_global_mutex_t *mutex);
\r
7657 apr_status_t apr_global_mutex_unlock(apr_global_mutex_t *mutex);
\r
7663 apr_status_t apr_global_mutex_destroy(apr_global_mutex_t *mutex);
\r
7669 const char * apr_global_mutex_lockfile(apr_global_mutex_t *mutex);
\r
7677 const char * apr_global_mutex_name(apr_global_mutex_t *mutex);
\r
7683 apr_pool_t * apr_global_mutex_pool_get (const apr_global_mutex_t *theglobal_mutex);
\r
7684 # 35 "../include/apr_portable.h" 2
\r
7687 # 1 "../include/apr_dso.h" 1
\r
7688 # 44 "../include/apr_dso.h"
\r
7689 typedef struct apr_dso_handle_t apr_dso_handle_t;
\r
7694 typedef void * apr_dso_handle_sym_t;
\r
7695 # 59 "../include/apr_dso.h"
\r
7696 apr_status_t apr_dso_load(apr_dso_handle_t **res_handle,
\r
7697 const char *path, apr_pool_t *ctx);
\r
7703 apr_status_t apr_dso_unload(apr_dso_handle_t *handle);
\r
7711 apr_status_t apr_dso_sym(apr_dso_handle_sym_t *ressym,
\r
7712 apr_dso_handle_t *handle,
\r
7713 const char *symname);
\r
7721 const char * apr_dso_error(apr_dso_handle_t *dso, char *buf, apr_size_t bufsize);
\r
7722 # 38 "../include/apr_portable.h" 2
\r
7723 # 1 "../include/apr_shm.h" 1
\r
7724 # 43 "../include/apr_shm.h"
\r
7725 typedef struct apr_shm_t apr_shm_t;
\r
7726 # 69 "../include/apr_shm.h"
\r
7727 apr_status_t apr_shm_create(apr_shm_t **m,
\r
7728 apr_size_t reqsize,
\r
7729 const char *filename,
\r
7730 apr_pool_t *pool);
\r
7731 # 114 "../include/apr_shm.h"
\r
7732 apr_status_t apr_shm_create_ex(apr_shm_t **m,
\r
7733 apr_size_t reqsize,
\r
7734 const char *filename,
\r
7736 apr_int32_t flags);
\r
7737 # 135 "../include/apr_shm.h"
\r
7738 apr_status_t apr_shm_remove(const char *filename,
\r
7739 apr_pool_t *pool);
\r
7745 apr_status_t apr_shm_destroy(apr_shm_t *m);
\r
7746 # 153 "../include/apr_shm.h"
\r
7747 apr_status_t apr_shm_attach(apr_shm_t **m,
\r
7748 const char *filename,
\r
7749 apr_pool_t *pool);
\r
7750 # 167 "../include/apr_shm.h"
\r
7751 apr_status_t apr_shm_attach_ex(apr_shm_t **m,
\r
7752 const char *filename,
\r
7754 apr_int32_t flags);
\r
7761 apr_status_t apr_shm_detach(apr_shm_t *m);
\r
7762 # 188 "../include/apr_shm.h"
\r
7763 void * apr_shm_baseaddr_get(const apr_shm_t *m);
\r
7770 apr_size_t apr_shm_size_get(const apr_shm_t *m);
\r
7775 apr_pool_t * apr_shm_pool_get (const apr_shm_t *theshm);
\r
7776 # 39 "../include/apr_portable.h" 2
\r
7779 # 1 "/usr/include/dirent.h" 1 3 4
\r
7780 # 61 "/usr/include/dirent.h" 3 4
\r
7781 # 1 "/usr/include/x86_64-linux-gnu/bits/dirent.h" 1 3 4
\r
7782 # 22 "/usr/include/x86_64-linux-gnu/bits/dirent.h" 3 4
\r
7792 unsigned short int d_reclen;
\r
7793 unsigned char d_type;
\r
7796 # 62 "/usr/include/dirent.h" 2 3 4
\r
7797 # 97 "/usr/include/dirent.h" 3 4
\r
7819 # 127 "/usr/include/dirent.h" 3 4
\r
7820 typedef struct __dirstream DIR;
\r
7827 extern DIR *opendir (const char *__name) __attribute__ ((__nonnull__ (1)));
\r
7834 extern DIR *fdopendir (int __fd);
\r
7842 extern int closedir (DIR *__dirp) __attribute__ ((__nonnull__ (1)));
\r
7843 # 162 "/usr/include/dirent.h" 3 4
\r
7844 extern struct dirent *readdir (DIR *__dirp) __attribute__ ((__nonnull__ (1)));
\r
7845 # 183 "/usr/include/dirent.h" 3 4
\r
7846 extern int readdir_r (DIR *__restrict __dirp,
\r
7847 struct dirent *__restrict __entry,
\r
7848 struct dirent **__restrict __result)
\r
7849 __attribute__ ((__nonnull__ (1, 2, 3)));
\r
7850 # 208 "/usr/include/dirent.h" 3 4
\r
7851 extern void rewinddir (DIR *__dirp) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
7857 extern void seekdir (DIR *__dirp, long int __pos) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
7860 extern long int telldir (DIR *__dirp) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
7866 extern int dirfd (DIR *__dirp) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
7867 # 244 "/usr/include/dirent.h" 3 4
\r
7868 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stddef.h" 1 3 4
\r
7869 # 245 "/usr/include/dirent.h" 2 3 4
\r
7870 # 254 "/usr/include/dirent.h" 3 4
\r
7871 extern int scandir (const char *__restrict __dir,
\r
7872 struct dirent ***__restrict __namelist,
\r
7873 int (*__selector) (const struct dirent *),
\r
7874 int (*__cmp) (const struct dirent **,
\r
7875 const struct dirent **))
\r
7876 __attribute__ ((__nonnull__ (1, 2)));
\r
7877 # 324 "/usr/include/dirent.h" 3 4
\r
7878 extern int alphasort (const struct dirent **__e1,
\r
7879 const struct dirent **__e2)
\r
7880 __attribute__ ((__nothrow__ )) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2)));
\r
7881 # 352 "/usr/include/dirent.h" 3 4
\r
7882 extern __ssize_t getdirentries (int __fd, char *__restrict __buf,
\r
7884 __off_t *__restrict __basep)
\r
7885 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2, 4)));
\r
7886 # 42 "../include/apr_portable.h" 2
\r
7889 # 1 "/usr/include/fcntl.h" 1 3 4
\r
7890 # 35 "/usr/include/fcntl.h" 3 4
\r
7891 # 1 "/usr/include/x86_64-linux-gnu/bits/fcntl.h" 1 3 4
\r
7892 # 35 "/usr/include/x86_64-linux-gnu/bits/fcntl.h" 3 4
\r
7896 short int l_whence;
\r
7906 # 61 "/usr/include/x86_64-linux-gnu/bits/fcntl.h" 3 4
\r
7907 # 1 "/usr/include/x86_64-linux-gnu/bits/fcntl-linux.h" 1 3 4
\r
7908 # 62 "/usr/include/x86_64-linux-gnu/bits/fcntl.h" 2 3 4
\r
7909 # 36 "/usr/include/fcntl.h" 2 3 4
\r
7910 # 67 "/usr/include/fcntl.h" 3 4
\r
7911 # 1 "/usr/include/time.h" 1 3 4
\r
7912 # 68 "/usr/include/fcntl.h" 2 3 4
\r
7913 # 1 "/usr/include/x86_64-linux-gnu/bits/stat.h" 1 3 4
\r
7914 # 46 "/usr/include/x86_64-linux-gnu/bits/stat.h" 3 4
\r
7930 __nlink_t st_nlink;
\r
7947 __blksize_t st_blksize;
\r
7949 __blkcnt_t st_blocks;
\r
7950 # 91 "/usr/include/x86_64-linux-gnu/bits/stat.h" 3 4
\r
7951 struct timespec st_atim;
\r
7952 struct timespec st_mtim;
\r
7953 struct timespec st_ctim;
\r
7954 # 106 "/usr/include/x86_64-linux-gnu/bits/stat.h" 3 4
\r
7955 __syscall_slong_t __glibc_reserved[3];
\r
7956 # 115 "/usr/include/x86_64-linux-gnu/bits/stat.h" 3 4
\r
7958 # 69 "/usr/include/fcntl.h" 2 3 4
\r
7959 # 137 "/usr/include/fcntl.h" 3 4
\r
7960 extern int fcntl (int __fd, int __cmd, ...);
\r
7961 # 146 "/usr/include/fcntl.h" 3 4
\r
7962 extern int open (const char *__file, int __oflag, ...) __attribute__ ((__nonnull__ (1)));
\r
7963 # 170 "/usr/include/fcntl.h" 3 4
\r
7964 extern int openat (int __fd, const char *__file, int __oflag, ...)
\r
7965 __attribute__ ((__nonnull__ (2)));
\r
7966 # 192 "/usr/include/fcntl.h" 3 4
\r
7967 extern int creat (const char *__file, mode_t __mode) __attribute__ ((__nonnull__ (1)));
\r
7968 # 238 "/usr/include/fcntl.h" 3 4
\r
7969 extern int posix_fadvise (int __fd, off_t __offset, off_t __len,
\r
7970 int __advise) __attribute__ ((__nothrow__ ));
\r
7971 # 260 "/usr/include/fcntl.h" 3 4
\r
7972 extern int posix_fallocate (int __fd, off_t __offset, off_t __len);
\r
7973 # 45 "../include/apr_portable.h" 2
\r
7976 # 1 "/usr/include/pthread.h" 1 3 4
\r
7977 # 23 "/usr/include/pthread.h" 3 4
\r
7978 # 1 "/usr/include/sched.h" 1 3 4
\r
7979 # 28 "/usr/include/sched.h" 3 4
\r
7980 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stddef.h" 1 3 4
\r
7981 # 29 "/usr/include/sched.h" 2 3 4
\r
7985 # 1 "/usr/include/time.h" 1 3 4
\r
7986 # 33 "/usr/include/sched.h" 2 3 4
\r
7995 # 1 "/usr/include/x86_64-linux-gnu/bits/sched.h" 1 3 4
\r
7996 # 72 "/usr/include/x86_64-linux-gnu/bits/sched.h" 3 4
\r
7997 struct sched_param
\r
7999 int __sched_priority;
\r
8001 # 103 "/usr/include/x86_64-linux-gnu/bits/sched.h" 3 4
\r
8002 struct __sched_param
\r
8004 int __sched_priority;
\r
8006 # 118 "/usr/include/x86_64-linux-gnu/bits/sched.h" 3 4
\r
8007 typedef unsigned long int __cpu_mask;
\r
8016 __cpu_mask __bits[1024 / (8 * sizeof (__cpu_mask))];
\r
8018 # 203 "/usr/include/x86_64-linux-gnu/bits/sched.h" 3 4
\r
8019 extern int __sched_cpucount (size_t __setsize, const cpu_set_t *__setp)
\r
8020 __attribute__ ((__nothrow__ ));
\r
8021 extern cpu_set_t *__sched_cpualloc (size_t __count) __attribute__ ((__nothrow__ )) ;
\r
8022 extern void __sched_cpufree (cpu_set_t *__set) __attribute__ ((__nothrow__ ));
\r
8023 # 42 "/usr/include/sched.h" 2 3 4
\r
8031 extern int sched_setparam (__pid_t __pid, const struct sched_param *__param)
\r
8032 __attribute__ ((__nothrow__ ));
\r
8035 extern int sched_getparam (__pid_t __pid, struct sched_param *__param) __attribute__ ((__nothrow__ ));
\r
8038 extern int sched_setscheduler (__pid_t __pid, int __policy,
\r
8039 const struct sched_param *__param) __attribute__ ((__nothrow__ ));
\r
8042 extern int sched_getscheduler (__pid_t __pid) __attribute__ ((__nothrow__ ));
\r
8045 extern int sched_yield (void) __attribute__ ((__nothrow__ ));
\r
8048 extern int sched_get_priority_max (int __algorithm) __attribute__ ((__nothrow__ ));
\r
8051 extern int sched_get_priority_min (int __algorithm) __attribute__ ((__nothrow__ ));
\r
8054 extern int sched_rr_get_interval (__pid_t __pid, struct timespec *__t) __attribute__ ((__nothrow__ ));
\r
8055 # 24 "/usr/include/pthread.h" 2 3 4
\r
8056 # 1 "/usr/include/time.h" 1 3 4
\r
8057 # 37 "/usr/include/time.h" 3 4
\r
8058 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stddef.h" 1 3 4
\r
8059 # 38 "/usr/include/time.h" 2 3 4
\r
8063 # 1 "/usr/include/x86_64-linux-gnu/bits/time.h" 1 3 4
\r
8064 # 42 "/usr/include/time.h" 2 3 4
\r
8065 # 133 "/usr/include/time.h" 3 4
\r
8079 long int tm_gmtoff;
\r
8080 const char *tm_zone;
\r
8086 # 161 "/usr/include/time.h" 3 4
\r
8089 struct timespec it_interval;
\r
8090 struct timespec it_value;
\r
8095 # 189 "/usr/include/time.h" 3 4
\r
8096 extern clock_t clock (void) __attribute__ ((__nothrow__ ));
\r
8099 extern time_t time (time_t *__timer) __attribute__ ((__nothrow__ ));
\r
8102 extern double difftime (time_t __time1, time_t __time0)
\r
8103 __attribute__ ((__nothrow__ )) __attribute__ ((__const__));
\r
8106 extern time_t mktime (struct tm *__tp) __attribute__ ((__nothrow__ ));
\r
8112 extern size_t strftime (char *__restrict __s, size_t __maxsize,
\r
8113 const char *__restrict __format,
\r
8114 const struct tm *__restrict __tp) __attribute__ ((__nothrow__ ));
\r
8115 # 223 "/usr/include/time.h" 3 4
\r
8116 extern size_t strftime_l (char *__restrict __s, size_t __maxsize,
\r
8117 const char *__restrict __format,
\r
8118 const struct tm *__restrict __tp,
\r
8119 __locale_t __loc) __attribute__ ((__nothrow__ ));
\r
8120 # 239 "/usr/include/time.h" 3 4
\r
8121 extern struct tm *gmtime (const time_t *__timer) __attribute__ ((__nothrow__ ));
\r
8125 extern struct tm *localtime (const time_t *__timer) __attribute__ ((__nothrow__ ));
\r
8131 extern struct tm *gmtime_r (const time_t *__restrict __timer,
\r
8132 struct tm *__restrict __tp) __attribute__ ((__nothrow__ ));
\r
8136 extern struct tm *localtime_r (const time_t *__restrict __timer,
\r
8137 struct tm *__restrict __tp) __attribute__ ((__nothrow__ ));
\r
8143 extern char *asctime (const struct tm *__tp) __attribute__ ((__nothrow__ ));
\r
8146 extern char *ctime (const time_t *__timer) __attribute__ ((__nothrow__ ));
\r
8154 extern char *asctime_r (const struct tm *__restrict __tp,
\r
8155 char *__restrict __buf) __attribute__ ((__nothrow__ ));
\r
8158 extern char *ctime_r (const time_t *__restrict __timer,
\r
8159 char *__restrict __buf) __attribute__ ((__nothrow__ ));
\r
8164 extern char *__tzname[2];
\r
8165 extern int __daylight;
\r
8166 extern long int __timezone;
\r
8171 extern char *tzname[2];
\r
8175 extern void tzset (void) __attribute__ ((__nothrow__ ));
\r
8179 extern int daylight;
\r
8180 extern long int timezone;
\r
8186 extern int stime (const time_t *__when) __attribute__ ((__nothrow__ ));
\r
8187 # 319 "/usr/include/time.h" 3 4
\r
8188 extern time_t timegm (struct tm *__tp) __attribute__ ((__nothrow__ ));
\r
8191 extern time_t timelocal (struct tm *__tp) __attribute__ ((__nothrow__ ));
\r
8194 extern int dysize (int __year) __attribute__ ((__nothrow__ )) __attribute__ ((__const__));
\r
8195 # 334 "/usr/include/time.h" 3 4
\r
8196 extern int nanosleep (const struct timespec *__requested_time,
\r
8197 struct timespec *__remaining);
\r
8201 extern int clock_getres (clockid_t __clock_id, struct timespec *__res) __attribute__ ((__nothrow__ ));
\r
8204 extern int clock_gettime (clockid_t __clock_id, struct timespec *__tp) __attribute__ ((__nothrow__ ));
\r
8207 extern int clock_settime (clockid_t __clock_id, const struct timespec *__tp)
\r
8208 __attribute__ ((__nothrow__ ));
\r
8215 extern int clock_nanosleep (clockid_t __clock_id, int __flags,
\r
8216 const struct timespec *__req,
\r
8217 struct timespec *__rem);
\r
8220 extern int clock_getcpuclockid (pid_t __pid, clockid_t *__clock_id) __attribute__ ((__nothrow__ ));
\r
8225 extern int timer_create (clockid_t __clock_id,
\r
8226 struct sigevent *__restrict __evp,
\r
8227 timer_t *__restrict __timerid) __attribute__ ((__nothrow__ ));
\r
8230 extern int timer_delete (timer_t __timerid) __attribute__ ((__nothrow__ ));
\r
8233 extern int timer_settime (timer_t __timerid, int __flags,
\r
8234 const struct itimerspec *__restrict __value,
\r
8235 struct itimerspec *__restrict __ovalue) __attribute__ ((__nothrow__ ));
\r
8238 extern int timer_gettime (timer_t __timerid, struct itimerspec *__value)
\r
8239 __attribute__ ((__nothrow__ ));
\r
8242 extern int timer_getoverrun (timer_t __timerid) __attribute__ ((__nothrow__ ));
\r
8243 # 25 "/usr/include/pthread.h" 2 3 4
\r
8246 # 1 "/usr/include/x86_64-linux-gnu/bits/setjmp.h" 1 3 4
\r
8247 # 26 "/usr/include/x86_64-linux-gnu/bits/setjmp.h" 3 4
\r
8248 # 1 "/usr/include/x86_64-linux-gnu/bits/wordsize.h" 1 3 4
\r
8249 # 27 "/usr/include/x86_64-linux-gnu/bits/setjmp.h" 2 3 4
\r
8254 typedef long int __jmp_buf[8];
\r
8255 # 28 "/usr/include/pthread.h" 2 3 4
\r
8256 # 1 "/usr/include/x86_64-linux-gnu/bits/wordsize.h" 1 3 4
\r
8257 # 29 "/usr/include/pthread.h" 2 3 4
\r
8263 PTHREAD_CREATE_JOINABLE,
\r
8265 PTHREAD_CREATE_DETACHED
\r
8273 PTHREAD_MUTEX_TIMED_NP,
\r
8274 PTHREAD_MUTEX_RECURSIVE_NP,
\r
8275 PTHREAD_MUTEX_ERRORCHECK_NP,
\r
8276 PTHREAD_MUTEX_ADAPTIVE_NP
\r
8279 PTHREAD_MUTEX_NORMAL = PTHREAD_MUTEX_TIMED_NP,
\r
8280 PTHREAD_MUTEX_RECURSIVE = PTHREAD_MUTEX_RECURSIVE_NP,
\r
8281 PTHREAD_MUTEX_ERRORCHECK = PTHREAD_MUTEX_ERRORCHECK_NP,
\r
8282 PTHREAD_MUTEX_DEFAULT = PTHREAD_MUTEX_NORMAL
\r
8295 PTHREAD_MUTEX_STALLED,
\r
8296 PTHREAD_MUTEX_STALLED_NP = PTHREAD_MUTEX_STALLED,
\r
8297 PTHREAD_MUTEX_ROBUST,
\r
8298 PTHREAD_MUTEX_ROBUST_NP = PTHREAD_MUTEX_ROBUST
\r
8307 PTHREAD_PRIO_NONE,
\r
8308 PTHREAD_PRIO_INHERIT,
\r
8309 PTHREAD_PRIO_PROTECT
\r
8311 # 125 "/usr/include/pthread.h" 3 4
\r
8314 PTHREAD_RWLOCK_PREFER_READER_NP,
\r
8315 PTHREAD_RWLOCK_PREFER_WRITER_NP,
\r
8316 PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP,
\r
8317 PTHREAD_RWLOCK_DEFAULT_NP = PTHREAD_RWLOCK_PREFER_READER_NP
\r
8319 # 166 "/usr/include/pthread.h" 3 4
\r
8322 PTHREAD_INHERIT_SCHED,
\r
8324 PTHREAD_EXPLICIT_SCHED
\r
8332 PTHREAD_SCOPE_SYSTEM,
\r
8334 PTHREAD_SCOPE_PROCESS
\r
8342 PTHREAD_PROCESS_PRIVATE,
\r
8344 PTHREAD_PROCESS_SHARED
\r
8347 # 201 "/usr/include/pthread.h" 3 4
\r
8348 struct _pthread_cleanup_buffer
\r
8350 void (*__routine) (void *);
\r
8353 struct _pthread_cleanup_buffer *__prev;
\r
8359 PTHREAD_CANCEL_ENABLE,
\r
8361 PTHREAD_CANCEL_DISABLE
\r
8366 PTHREAD_CANCEL_DEFERRED,
\r
8368 PTHREAD_CANCEL_ASYNCHRONOUS
\r
8371 # 244 "/usr/include/pthread.h" 3 4
\r
8372 extern int pthread_create (pthread_t *__restrict __newthread,
\r
8373 const pthread_attr_t *__restrict __attr,
\r
8374 void *(*__start_routine) (void *),
\r
8375 void *__restrict __arg) __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1, 3)));
\r
8381 extern void pthread_exit (void *__retval) __attribute__ ((__noreturn__));
\r
8389 extern int pthread_join (pthread_t __th, void **__thread_return);
\r
8390 # 282 "/usr/include/pthread.h" 3 4
\r
8391 extern int pthread_detach (pthread_t __th) __attribute__ ((__nothrow__ ));
\r
8395 extern pthread_t pthread_self (void) __attribute__ ((__nothrow__ )) __attribute__ ((__const__));
\r
8398 extern int pthread_equal (pthread_t __thread1, pthread_t __thread2)
\r
8399 __attribute__ ((__nothrow__ )) __attribute__ ((__const__));
\r
8407 extern int pthread_attr_init (pthread_attr_t *__attr) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8410 extern int pthread_attr_destroy (pthread_attr_t *__attr)
\r
8411 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8414 extern int pthread_attr_getdetachstate (const pthread_attr_t *__attr,
\r
8415 int *__detachstate)
\r
8416 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8419 extern int pthread_attr_setdetachstate (pthread_attr_t *__attr,
\r
8420 int __detachstate)
\r
8421 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8425 extern int pthread_attr_getguardsize (const pthread_attr_t *__attr,
\r
8426 size_t *__guardsize)
\r
8427 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8430 extern int pthread_attr_setguardsize (pthread_attr_t *__attr,
\r
8431 size_t __guardsize)
\r
8432 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8436 extern int pthread_attr_getschedparam (const pthread_attr_t *__restrict __attr,
\r
8437 struct sched_param *__restrict __param)
\r
8438 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8441 extern int pthread_attr_setschedparam (pthread_attr_t *__restrict __attr,
\r
8442 const struct sched_param *__restrict
\r
8443 __param) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8446 extern int pthread_attr_getschedpolicy (const pthread_attr_t *__restrict
\r
8447 __attr, int *__restrict __policy)
\r
8448 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8451 extern int pthread_attr_setschedpolicy (pthread_attr_t *__attr, int __policy)
\r
8452 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8455 extern int pthread_attr_getinheritsched (const pthread_attr_t *__restrict
\r
8456 __attr, int *__restrict __inherit)
\r
8457 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8460 extern int pthread_attr_setinheritsched (pthread_attr_t *__attr,
\r
8462 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8466 extern int pthread_attr_getscope (const pthread_attr_t *__restrict __attr,
\r
8467 int *__restrict __scope)
\r
8468 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8471 extern int pthread_attr_setscope (pthread_attr_t *__attr, int __scope)
\r
8472 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8475 extern int pthread_attr_getstackaddr (const pthread_attr_t *__restrict
\r
8476 __attr, void **__restrict __stackaddr)
\r
8477 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2))) __attribute__ ((__deprecated__));
\r
8483 extern int pthread_attr_setstackaddr (pthread_attr_t *__attr,
\r
8484 void *__stackaddr)
\r
8485 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1))) __attribute__ ((__deprecated__));
\r
8488 extern int pthread_attr_getstacksize (const pthread_attr_t *__restrict
\r
8489 __attr, size_t *__restrict __stacksize)
\r
8490 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8495 extern int pthread_attr_setstacksize (pthread_attr_t *__attr,
\r
8496 size_t __stacksize)
\r
8497 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8501 extern int pthread_attr_getstack (const pthread_attr_t *__restrict __attr,
\r
8502 void **__restrict __stackaddr,
\r
8503 size_t *__restrict __stacksize)
\r
8504 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2, 3)));
\r
8509 extern int pthread_attr_setstack (pthread_attr_t *__attr, void *__stackaddr,
\r
8510 size_t __stacksize) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8511 # 440 "/usr/include/pthread.h" 3 4
\r
8512 extern int pthread_setschedparam (pthread_t __target_thread, int __policy,
\r
8513 const struct sched_param *__param)
\r
8514 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (3)));
\r
8517 extern int pthread_getschedparam (pthread_t __target_thread,
\r
8518 int *__restrict __policy,
\r
8519 struct sched_param *__restrict __param)
\r
8520 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2, 3)));
\r
8523 extern int pthread_setschedprio (pthread_t __target_thread, int __prio)
\r
8524 __attribute__ ((__nothrow__ ));
\r
8525 # 505 "/usr/include/pthread.h" 3 4
\r
8526 extern int pthread_once (pthread_once_t *__once_control,
\r
8527 void (*__init_routine) (void)) __attribute__ ((__nonnull__ (1, 2)));
\r
8528 # 517 "/usr/include/pthread.h" 3 4
\r
8529 extern int pthread_setcancelstate (int __state, int *__oldstate);
\r
8533 extern int pthread_setcanceltype (int __type, int *__oldtype);
\r
8536 extern int pthread_cancel (pthread_t __th);
\r
8541 extern void pthread_testcancel (void);
\r
8550 __jmp_buf __cancel_jmp_buf;
\r
8551 int __mask_was_saved;
\r
8552 } __cancel_jmp_buf[1];
\r
8554 } __pthread_unwind_buf_t __attribute__ ((__aligned__));
\r
8555 # 551 "/usr/include/pthread.h" 3 4
\r
8556 struct __pthread_cleanup_frame
\r
8558 void (*__cancel_routine) (void *);
\r
8559 void *__cancel_arg;
\r
8561 int __cancel_type;
\r
8563 # 691 "/usr/include/pthread.h" 3 4
\r
8564 extern void __pthread_register_cancel (__pthread_unwind_buf_t *__buf)
\r
8566 # 703 "/usr/include/pthread.h" 3 4
\r
8567 extern void __pthread_unregister_cancel (__pthread_unwind_buf_t *__buf)
\r
8569 # 744 "/usr/include/pthread.h" 3 4
\r
8570 extern void __pthread_unwind_next (__pthread_unwind_buf_t *__buf)
\r
8571 __attribute__ ((__noreturn__))
\r
8573 __attribute__ ((__weak__))
\r
8579 struct __jmp_buf_tag;
\r
8580 extern int __sigsetjmp (struct __jmp_buf_tag *__env, int __savemask) __attribute__ ((__nothrow__));
\r
8586 extern int pthread_mutex_init (pthread_mutex_t *__mutex,
\r
8587 const pthread_mutexattr_t *__mutexattr)
\r
8588 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8591 extern int pthread_mutex_destroy (pthread_mutex_t *__mutex)
\r
8592 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8595 extern int pthread_mutex_trylock (pthread_mutex_t *__mutex)
\r
8596 __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1)));
\r
8599 extern int pthread_mutex_lock (pthread_mutex_t *__mutex)
\r
8600 __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1)));
\r
8604 extern int pthread_mutex_timedlock (pthread_mutex_t *__restrict __mutex,
\r
8605 const struct timespec *__restrict
\r
8606 __abstime) __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1, 2)));
\r
8610 extern int pthread_mutex_unlock (pthread_mutex_t *__mutex)
\r
8611 __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1)));
\r
8615 extern int pthread_mutex_getprioceiling (const pthread_mutex_t *
\r
8616 __restrict __mutex,
\r
8617 int *__restrict __prioceiling)
\r
8618 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8622 extern int pthread_mutex_setprioceiling (pthread_mutex_t *__restrict __mutex,
\r
8623 int __prioceiling,
\r
8624 int *__restrict __old_ceiling)
\r
8625 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 3)));
\r
8630 extern int pthread_mutex_consistent (pthread_mutex_t *__mutex)
\r
8631 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8632 # 817 "/usr/include/pthread.h" 3 4
\r
8633 extern int pthread_mutexattr_init (pthread_mutexattr_t *__attr)
\r
8634 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8637 extern int pthread_mutexattr_destroy (pthread_mutexattr_t *__attr)
\r
8638 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8641 extern int pthread_mutexattr_getpshared (const pthread_mutexattr_t *
\r
8642 __restrict __attr,
\r
8643 int *__restrict __pshared)
\r
8644 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8647 extern int pthread_mutexattr_setpshared (pthread_mutexattr_t *__attr,
\r
8649 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8653 extern int pthread_mutexattr_gettype (const pthread_mutexattr_t *__restrict
\r
8654 __attr, int *__restrict __kind)
\r
8655 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8660 extern int pthread_mutexattr_settype (pthread_mutexattr_t *__attr, int __kind)
\r
8661 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8665 extern int pthread_mutexattr_getprotocol (const pthread_mutexattr_t *
\r
8666 __restrict __attr,
\r
8667 int *__restrict __protocol)
\r
8668 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8672 extern int pthread_mutexattr_setprotocol (pthread_mutexattr_t *__attr,
\r
8674 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8677 extern int pthread_mutexattr_getprioceiling (const pthread_mutexattr_t *
\r
8678 __restrict __attr,
\r
8679 int *__restrict __prioceiling)
\r
8680 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8683 extern int pthread_mutexattr_setprioceiling (pthread_mutexattr_t *__attr,
\r
8684 int __prioceiling)
\r
8685 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8689 extern int pthread_mutexattr_getrobust (const pthread_mutexattr_t *__attr,
\r
8690 int *__robustness)
\r
8691 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8699 extern int pthread_mutexattr_setrobust (pthread_mutexattr_t *__attr,
\r
8701 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8702 # 899 "/usr/include/pthread.h" 3 4
\r
8703 extern int pthread_rwlock_init (pthread_rwlock_t *__restrict __rwlock,
\r
8704 const pthread_rwlockattr_t *__restrict
\r
8705 __attr) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8708 extern int pthread_rwlock_destroy (pthread_rwlock_t *__rwlock)
\r
8709 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8712 extern int pthread_rwlock_rdlock (pthread_rwlock_t *__rwlock)
\r
8713 __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1)));
\r
8716 extern int pthread_rwlock_tryrdlock (pthread_rwlock_t *__rwlock)
\r
8717 __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1)));
\r
8721 extern int pthread_rwlock_timedrdlock (pthread_rwlock_t *__restrict __rwlock,
\r
8722 const struct timespec *__restrict
\r
8723 __abstime) __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1, 2)));
\r
8727 extern int pthread_rwlock_wrlock (pthread_rwlock_t *__rwlock)
\r
8728 __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1)));
\r
8731 extern int pthread_rwlock_trywrlock (pthread_rwlock_t *__rwlock)
\r
8732 __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1)));
\r
8736 extern int pthread_rwlock_timedwrlock (pthread_rwlock_t *__restrict __rwlock,
\r
8737 const struct timespec *__restrict
\r
8738 __abstime) __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1, 2)));
\r
8742 extern int pthread_rwlock_unlock (pthread_rwlock_t *__rwlock)
\r
8743 __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1)));
\r
8749 extern int pthread_rwlockattr_init (pthread_rwlockattr_t *__attr)
\r
8750 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8753 extern int pthread_rwlockattr_destroy (pthread_rwlockattr_t *__attr)
\r
8754 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8757 extern int pthread_rwlockattr_getpshared (const pthread_rwlockattr_t *
\r
8758 __restrict __attr,
\r
8759 int *__restrict __pshared)
\r
8760 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8763 extern int pthread_rwlockattr_setpshared (pthread_rwlockattr_t *__attr,
\r
8765 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8768 extern int pthread_rwlockattr_getkind_np (const pthread_rwlockattr_t *
\r
8769 __restrict __attr,
\r
8770 int *__restrict __pref)
\r
8771 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8774 extern int pthread_rwlockattr_setkind_np (pthread_rwlockattr_t *__attr,
\r
8775 int __pref) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8783 extern int pthread_cond_init (pthread_cond_t *__restrict __cond,
\r
8784 const pthread_condattr_t *__restrict __cond_attr)
\r
8785 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8788 extern int pthread_cond_destroy (pthread_cond_t *__cond)
\r
8789 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8792 extern int pthread_cond_signal (pthread_cond_t *__cond)
\r
8793 __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1)));
\r
8796 extern int pthread_cond_broadcast (pthread_cond_t *__cond)
\r
8797 __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1)));
\r
8804 extern int pthread_cond_wait (pthread_cond_t *__restrict __cond,
\r
8805 pthread_mutex_t *__restrict __mutex)
\r
8806 __attribute__ ((__nonnull__ (1, 2)));
\r
8807 # 1011 "/usr/include/pthread.h" 3 4
\r
8808 extern int pthread_cond_timedwait (pthread_cond_t *__restrict __cond,
\r
8809 pthread_mutex_t *__restrict __mutex,
\r
8810 const struct timespec *__restrict __abstime)
\r
8811 __attribute__ ((__nonnull__ (1, 2, 3)));
\r
8816 extern int pthread_condattr_init (pthread_condattr_t *__attr)
\r
8817 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8820 extern int pthread_condattr_destroy (pthread_condattr_t *__attr)
\r
8821 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8824 extern int pthread_condattr_getpshared (const pthread_condattr_t *
\r
8825 __restrict __attr,
\r
8826 int *__restrict __pshared)
\r
8827 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8830 extern int pthread_condattr_setpshared (pthread_condattr_t *__attr,
\r
8831 int __pshared) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8835 extern int pthread_condattr_getclock (const pthread_condattr_t *
\r
8836 __restrict __attr,
\r
8837 __clockid_t *__restrict __clock_id)
\r
8838 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8841 extern int pthread_condattr_setclock (pthread_condattr_t *__attr,
\r
8842 __clockid_t __clock_id)
\r
8843 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8844 # 1055 "/usr/include/pthread.h" 3 4
\r
8845 extern int pthread_spin_init (pthread_spinlock_t *__lock, int __pshared)
\r
8846 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8849 extern int pthread_spin_destroy (pthread_spinlock_t *__lock)
\r
8850 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8853 extern int pthread_spin_lock (pthread_spinlock_t *__lock)
\r
8854 __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1)));
\r
8857 extern int pthread_spin_trylock (pthread_spinlock_t *__lock)
\r
8858 __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1)));
\r
8861 extern int pthread_spin_unlock (pthread_spinlock_t *__lock)
\r
8862 __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1)));
\r
8869 extern int pthread_barrier_init (pthread_barrier_t *__restrict __barrier,
\r
8870 const pthread_barrierattr_t *__restrict
\r
8871 __attr, unsigned int __count)
\r
8872 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8875 extern int pthread_barrier_destroy (pthread_barrier_t *__barrier)
\r
8876 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8879 extern int pthread_barrier_wait (pthread_barrier_t *__barrier)
\r
8880 __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1)));
\r
8884 extern int pthread_barrierattr_init (pthread_barrierattr_t *__attr)
\r
8885 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8888 extern int pthread_barrierattr_destroy (pthread_barrierattr_t *__attr)
\r
8889 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8892 extern int pthread_barrierattr_getpshared (const pthread_barrierattr_t *
\r
8893 __restrict __attr,
\r
8894 int *__restrict __pshared)
\r
8895 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
8898 extern int pthread_barrierattr_setpshared (pthread_barrierattr_t *__attr,
\r
8900 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8901 # 1122 "/usr/include/pthread.h" 3 4
\r
8902 extern int pthread_key_create (pthread_key_t *__key,
\r
8903 void (*__destr_function) (void *))
\r
8904 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
8907 extern int pthread_key_delete (pthread_key_t __key) __attribute__ ((__nothrow__ ));
\r
8910 extern void *pthread_getspecific (pthread_key_t __key) __attribute__ ((__nothrow__ ));
\r
8913 extern int pthread_setspecific (pthread_key_t __key,
\r
8914 const void *__pointer) __attribute__ ((__nothrow__ )) ;
\r
8919 extern int pthread_getcpuclockid (pthread_t __thread_id,
\r
8920 __clockid_t *__clock_id)
\r
8921 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2)));
\r
8922 # 1156 "/usr/include/pthread.h" 3 4
\r
8923 extern int pthread_atfork (void (*__prepare) (void),
\r
8924 void (*__parent) (void),
\r
8925 void (*__child) (void)) __attribute__ ((__nothrow__ ));
\r
8926 # 48 "../include/apr_portable.h" 2
\r
8927 # 127 "../include/apr_portable.h"
\r
8928 struct apr_os_proc_mutex_t {
\r
8935 pthread_mutex_t *pthread_interproc;
\r
8941 pthread_mutex_t *intraproc;
\r
8946 typedef int apr_os_file_t;
\r
8947 typedef DIR apr_os_dir_t;
\r
8948 typedef int apr_os_sock_t;
\r
8949 typedef struct apr_os_proc_mutex_t apr_os_proc_mutex_t;
\r
8953 typedef pthread_t apr_os_thread_t;
\r
8954 typedef pthread_key_t apr_os_threadkey_t;
\r
8957 typedef pid_t apr_os_proc_t;
\r
8958 typedef struct timeval apr_os_imp_time_t;
\r
8959 typedef struct tm apr_os_exp_time_t;
\r
8960 # 169 "../include/apr_portable.h"
\r
8961 typedef void * apr_os_dso_handle_t;
\r
8963 typedef void* apr_os_shm_t;
\r
8964 # 183 "../include/apr_portable.h"
\r
8965 struct apr_os_sock_info_t {
\r
8966 apr_os_sock_t *os_sock;
\r
8967 struct sockaddr *local;
\r
8968 struct sockaddr *remote;
\r
8974 typedef struct apr_os_sock_info_t apr_os_sock_info_t;
\r
8975 # 203 "../include/apr_portable.h"
\r
8976 struct apr_os_global_mutex_t {
\r
8978 apr_proc_mutex_t *proc_mutex;
\r
8980 apr_thread_mutex_t *thread_mutex;
\r
8983 typedef struct apr_os_global_mutex_t apr_os_global_mutex_t;
\r
8985 apr_status_t apr_os_global_mutex_get(apr_os_global_mutex_t *ospmutex,
\r
8986 apr_global_mutex_t *pmutex);
\r
8987 # 224 "../include/apr_portable.h"
\r
8988 apr_status_t apr_os_file_get(apr_os_file_t *thefile,
\r
8989 apr_file_t *file);
\r
8996 apr_status_t apr_os_dir_get(apr_os_dir_t **thedir,
\r
9004 apr_status_t apr_os_sock_get(apr_os_sock_t *thesock,
\r
9005 apr_socket_t *sock);
\r
9012 apr_status_t apr_os_proc_mutex_get(apr_os_proc_mutex_t *ospmutex,
\r
9013 apr_proc_mutex_t *pmutex);
\r
9020 apr_status_t apr_os_exp_time_get(apr_os_exp_time_t **ostime,
\r
9021 apr_time_exp_t *aprtime);
\r
9028 apr_status_t apr_os_imp_time_get(apr_os_imp_time_t **ostime,
\r
9029 apr_time_t *aprtime);
\r
9036 apr_status_t apr_os_shm_get(apr_os_shm_t *osshm,
\r
9038 # 285 "../include/apr_portable.h"
\r
9039 apr_status_t apr_os_thread_get(apr_os_thread_t **thethd,
\r
9040 apr_thread_t *thd);
\r
9047 apr_status_t apr_os_threadkey_get(apr_os_threadkey_t *thekey,
\r
9048 apr_threadkey_t *key);
\r
9056 apr_status_t apr_os_thread_put(apr_thread_t **thd,
\r
9057 apr_os_thread_t *thethd,
\r
9058 apr_pool_t *cont);
\r
9066 apr_status_t apr_os_threadkey_put(apr_threadkey_t **key,
\r
9067 apr_os_threadkey_t *thekey,
\r
9068 apr_pool_t *cont);
\r
9072 apr_os_thread_t apr_os_thread_current(void);
\r
9080 int apr_os_thread_equal(apr_os_thread_t tid1,
\r
9081 apr_os_thread_t tid2);
\r
9082 # 341 "../include/apr_portable.h"
\r
9083 apr_status_t apr_os_file_put(apr_file_t **file,
\r
9084 apr_os_file_t *thefile,
\r
9085 apr_int32_t flags, apr_pool_t *cont);
\r
9086 # 353 "../include/apr_portable.h"
\r
9087 apr_status_t apr_os_pipe_put(apr_file_t **file,
\r
9088 apr_os_file_t *thefile,
\r
9089 apr_pool_t *cont);
\r
9090 # 367 "../include/apr_portable.h"
\r
9091 apr_status_t apr_os_pipe_put_ex(apr_file_t **file,
\r
9092 apr_os_file_t *thefile,
\r
9093 int register_cleanup,
\r
9094 apr_pool_t *cont);
\r
9102 apr_status_t apr_os_dir_put(apr_dir_t **dir,
\r
9103 apr_os_dir_t *thedir,
\r
9104 apr_pool_t *cont);
\r
9105 # 390 "../include/apr_portable.h"
\r
9106 apr_status_t apr_os_sock_put(apr_socket_t **sock,
\r
9107 apr_os_sock_t *thesock,
\r
9108 apr_pool_t *cont);
\r
9109 # 404 "../include/apr_portable.h"
\r
9110 apr_status_t apr_os_sock_make(apr_socket_t **apr_sock,
\r
9111 apr_os_sock_info_t *os_sock_info,
\r
9112 apr_pool_t *cont);
\r
9120 apr_status_t apr_os_proc_mutex_put(apr_proc_mutex_t **pmutex,
\r
9121 apr_os_proc_mutex_t *ospmutex,
\r
9122 apr_pool_t *cont);
\r
9130 apr_status_t apr_os_imp_time_put(apr_time_t *aprtime,
\r
9131 apr_os_imp_time_t **ostime,
\r
9132 apr_pool_t *cont);
\r
9140 apr_status_t apr_os_exp_time_put(apr_time_exp_t *aprtime,
\r
9141 apr_os_exp_time_t **ostime,
\r
9142 apr_pool_t *cont);
\r
9143 # 447 "../include/apr_portable.h"
\r
9144 apr_status_t apr_os_shm_put(apr_shm_t **shm,
\r
9145 apr_os_shm_t *osshm,
\r
9146 apr_pool_t *cont);
\r
9147 # 463 "../include/apr_portable.h"
\r
9148 apr_status_t apr_os_dso_handle_put(apr_dso_handle_t **dso,
\r
9149 apr_os_dso_handle_t thedso,
\r
9150 apr_pool_t *pool);
\r
9157 apr_status_t apr_os_dso_handle_get(apr_os_dso_handle_t *dso,
\r
9158 apr_dso_handle_t *aprdso);
\r
9159 # 491 "../include/apr_portable.h"
\r
9160 const char* apr_os_default_encoding(apr_pool_t *pool);
\r
9161 # 500 "../include/apr_portable.h"
\r
9162 const char* apr_os_locale_encoding(apr_pool_t *pool);
\r
9163 # 25 "../include/arch/unix/apr_arch_thread_mutex.h" 2
\r
9171 struct apr_thread_mutex_t {
\r
9173 pthread_mutex_t mutex;
\r
9175 # 18 "./../locks/unix/thread_mutex.c" 2
\r
9177 # 1 "../include/apr_want.h" 1
\r
9178 # 20 "./../locks/unix/thread_mutex.c" 2
\r
9182 static apr_status_t thread_mutex_cleanup(void *data)
\r
9184 apr_thread_mutex_t *mutex = data;
\r
9187 rv = pthread_mutex_destroy(&mutex->mutex);
\r
9196 apr_status_t apr_thread_mutex_create(apr_thread_mutex_t **mutex,
\r
9197 unsigned int flags,
\r
9200 apr_thread_mutex_t *new_mutex;
\r
9209 new_mutex = memset(apr_palloc(pool, sizeof(apr_thread_mutex_t)), 0, sizeof(apr_thread_mutex_t));
\r
9210 new_mutex->pool = pool;
\r
9213 if (flags & 0x1) {
\r
9214 pthread_mutexattr_t mattr;
\r
9216 rv = pthread_mutexattr_init(&mattr);
\r
9217 if (rv) return rv;
\r
9219 rv = pthread_mutexattr_settype(&mattr, PTHREAD_MUTEX_RECURSIVE);
\r
9221 pthread_mutexattr_destroy(&mattr);
\r
9225 rv = pthread_mutex_init(&new_mutex->mutex, &mattr);
\r
9227 pthread_mutexattr_destroy(&mattr);
\r
9230 rv = pthread_mutex_init(&new_mutex->mutex, ((void*)0));
\r
9239 apr_pool_cleanup_register(new_mutex->pool,
\r
9240 new_mutex, thread_mutex_cleanup,
\r
9241 apr_pool_cleanup_null);
\r
9243 *mutex = new_mutex;
\r
9247 apr_status_t apr_thread_mutex_lock(apr_thread_mutex_t *mutex)
\r
9251 rv = pthread_mutex_lock(&mutex->mutex);
\r
9261 apr_status_t apr_thread_mutex_trylock(apr_thread_mutex_t *mutex)
\r
9265 rv = pthread_mutex_trylock(&mutex->mutex);
\r
9270 return (rv == 16) ? ((20000 + 50000) + 25) : rv;
\r
9276 apr_status_t apr_thread_mutex_unlock(apr_thread_mutex_t *mutex)
\r
9278 apr_status_t status;
\r
9280 status = pthread_mutex_unlock(&mutex->mutex);
\r
9290 apr_status_t apr_thread_mutex_destroy(apr_thread_mutex_t *mutex)
\r
9292 return apr_pool_cleanup_run(mutex->pool, mutex, thread_mutex_cleanup);
\r
9295 apr_pool_t * apr_thread_mutex_pool_get (const apr_thread_mutex_t *thethread_mutex) { return thethread_mutex->pool; }
\r
9297 # 1 "./../locks/unix/proc_mutex.c" 1
\r
9298 # 19 "./../locks/unix/proc_mutex.c"
\r
9299 # 1 "../include/arch/unix/apr_arch_proc_mutex.h" 1
\r
9300 # 23 "../include/arch/unix/apr_arch_proc_mutex.h"
\r
9301 # 1 "../include/apr_lib.h" 1
\r
9302 # 32 "../include/apr_lib.h"
\r
9303 # 1 "/usr/include/ctype.h" 1 3 4
\r
9304 # 46 "/usr/include/ctype.h" 3 4
\r
9307 _ISupper = ((0) < 8 ? ((1 << (0)) << 8) : ((1 << (0)) >> 8)),
\r
9308 _ISlower = ((1) < 8 ? ((1 << (1)) << 8) : ((1 << (1)) >> 8)),
\r
9309 _ISalpha = ((2) < 8 ? ((1 << (2)) << 8) : ((1 << (2)) >> 8)),
\r
9310 _ISdigit = ((3) < 8 ? ((1 << (3)) << 8) : ((1 << (3)) >> 8)),
\r
9311 _ISxdigit = ((4) < 8 ? ((1 << (4)) << 8) : ((1 << (4)) >> 8)),
\r
9312 _ISspace = ((5) < 8 ? ((1 << (5)) << 8) : ((1 << (5)) >> 8)),
\r
9313 _ISprint = ((6) < 8 ? ((1 << (6)) << 8) : ((1 << (6)) >> 8)),
\r
9314 _ISgraph = ((7) < 8 ? ((1 << (7)) << 8) : ((1 << (7)) >> 8)),
\r
9315 _ISblank = ((8) < 8 ? ((1 << (8)) << 8) : ((1 << (8)) >> 8)),
\r
9316 _IScntrl = ((9) < 8 ? ((1 << (9)) << 8) : ((1 << (9)) >> 8)),
\r
9317 _ISpunct = ((10) < 8 ? ((1 << (10)) << 8) : ((1 << (10)) >> 8)),
\r
9318 _ISalnum = ((11) < 8 ? ((1 << (11)) << 8) : ((1 << (11)) >> 8))
\r
9320 # 79 "/usr/include/ctype.h" 3 4
\r
9321 extern const unsigned short int **__ctype_b_loc (void)
\r
9322 __attribute__ ((__nothrow__ )) __attribute__ ((__const__));
\r
9323 extern const __int32_t **__ctype_tolower_loc (void)
\r
9324 __attribute__ ((__nothrow__ )) __attribute__ ((__const__));
\r
9325 extern const __int32_t **__ctype_toupper_loc (void)
\r
9326 __attribute__ ((__nothrow__ )) __attribute__ ((__const__));
\r
9327 # 110 "/usr/include/ctype.h" 3 4
\r
9328 extern int isalnum (int) __attribute__ ((__nothrow__ ));
\r
9329 extern int isalpha (int) __attribute__ ((__nothrow__ ));
\r
9330 extern int iscntrl (int) __attribute__ ((__nothrow__ ));
\r
9331 extern int isdigit (int) __attribute__ ((__nothrow__ ));
\r
9332 extern int islower (int) __attribute__ ((__nothrow__ ));
\r
9333 extern int isgraph (int) __attribute__ ((__nothrow__ ));
\r
9334 extern int isprint (int) __attribute__ ((__nothrow__ ));
\r
9335 extern int ispunct (int) __attribute__ ((__nothrow__ ));
\r
9336 extern int isspace (int) __attribute__ ((__nothrow__ ));
\r
9337 extern int isupper (int) __attribute__ ((__nothrow__ ));
\r
9338 extern int isxdigit (int) __attribute__ ((__nothrow__ ));
\r
9342 extern int tolower (int __c) __attribute__ ((__nothrow__ ));
\r
9345 extern int toupper (int __c) __attribute__ ((__nothrow__ ));
\r
9346 # 136 "/usr/include/ctype.h" 3 4
\r
9347 extern int isblank (int) __attribute__ ((__nothrow__ ));
\r
9348 # 150 "/usr/include/ctype.h" 3 4
\r
9349 extern int isascii (int __c) __attribute__ ((__nothrow__ ));
\r
9353 extern int toascii (int __c) __attribute__ ((__nothrow__ ));
\r
9357 extern int _toupper (int) __attribute__ ((__nothrow__ ));
\r
9358 extern int _tolower (int) __attribute__ ((__nothrow__ ));
\r
9359 # 271 "/usr/include/ctype.h" 3 4
\r
9360 extern int isalnum_l (int, __locale_t) __attribute__ ((__nothrow__ ));
\r
9361 extern int isalpha_l (int, __locale_t) __attribute__ ((__nothrow__ ));
\r
9362 extern int iscntrl_l (int, __locale_t) __attribute__ ((__nothrow__ ));
\r
9363 extern int isdigit_l (int, __locale_t) __attribute__ ((__nothrow__ ));
\r
9364 extern int islower_l (int, __locale_t) __attribute__ ((__nothrow__ ));
\r
9365 extern int isgraph_l (int, __locale_t) __attribute__ ((__nothrow__ ));
\r
9366 extern int isprint_l (int, __locale_t) __attribute__ ((__nothrow__ ));
\r
9367 extern int ispunct_l (int, __locale_t) __attribute__ ((__nothrow__ ));
\r
9368 extern int isspace_l (int, __locale_t) __attribute__ ((__nothrow__ ));
\r
9369 extern int isupper_l (int, __locale_t) __attribute__ ((__nothrow__ ));
\r
9370 extern int isxdigit_l (int, __locale_t) __attribute__ ((__nothrow__ ));
\r
9372 extern int isblank_l (int, __locale_t) __attribute__ ((__nothrow__ ));
\r
9376 extern int __tolower_l (int __c, __locale_t __l) __attribute__ ((__nothrow__ ));
\r
9377 extern int tolower_l (int __c, __locale_t __l) __attribute__ ((__nothrow__ ));
\r
9380 extern int __toupper_l (int __c, __locale_t __l) __attribute__ ((__nothrow__ ));
\r
9381 extern int toupper_l (int __c, __locale_t __l) __attribute__ ((__nothrow__ ));
\r
9382 # 33 "../include/apr_lib.h" 2
\r
9383 # 59 "../include/apr_lib.h"
\r
9384 typedef struct apr_vformatter_buff_t apr_vformatter_buff_t;
\r
9389 struct apr_vformatter_buff_t {
\r
9395 # 84 "../include/apr_lib.h"
\r
9396 const char * apr_filepath_name_get(const char *pathname);
\r
9397 # 174 "../include/apr_lib.h"
\r
9398 int apr_vformatter(int (*flush_func)(apr_vformatter_buff_t *b),
\r
9399 apr_vformatter_buff_t *c, const char *fmt,
\r
9401 # 189 "../include/apr_lib.h"
\r
9402 apr_status_t apr_password_get(const char *prompt, char *pwbuf,
\r
9403 apr_size_t *bufsize);
\r
9404 # 24 "../include/arch/unix/apr_arch_proc_mutex.h" 2
\r
9409 # 1 "../include/arch/unix/apr_arch_file_io.h" 1
\r
9410 # 41 "../include/arch/unix/apr_arch_file_io.h"
\r
9411 # 1 "/usr/include/errno.h" 1 3 4
\r
9412 # 42 "../include/arch/unix/apr_arch_file_io.h" 2
\r
9418 # 1 "/usr/include/strings.h" 1 3 4
\r
9419 # 48 "../include/arch/unix/apr_arch_file_io.h" 2
\r
9425 # 1 "/usr/include/x86_64-linux-gnu/sys/stat.h" 1 3 4
\r
9426 # 105 "/usr/include/x86_64-linux-gnu/sys/stat.h" 3 4
\r
9427 # 1 "/usr/include/x86_64-linux-gnu/bits/stat.h" 1 3 4
\r
9428 # 106 "/usr/include/x86_64-linux-gnu/sys/stat.h" 2 3 4
\r
9429 # 209 "/usr/include/x86_64-linux-gnu/sys/stat.h" 3 4
\r
9430 extern int stat (const char *__restrict __file,
\r
9431 struct stat *__restrict __buf) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
9435 extern int fstat (int __fd, struct stat *__buf) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2)));
\r
9436 # 238 "/usr/include/x86_64-linux-gnu/sys/stat.h" 3 4
\r
9437 extern int fstatat (int __fd, const char *__restrict __file,
\r
9438 struct stat *__restrict __buf, int __flag)
\r
9439 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2, 3)));
\r
9440 # 263 "/usr/include/x86_64-linux-gnu/sys/stat.h" 3 4
\r
9441 extern int lstat (const char *__restrict __file,
\r
9442 struct stat *__restrict __buf) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1, 2)));
\r
9443 # 284 "/usr/include/x86_64-linux-gnu/sys/stat.h" 3 4
\r
9444 extern int chmod (const char *__file, __mode_t __mode)
\r
9445 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
9451 extern int lchmod (const char *__file, __mode_t __mode)
\r
9452 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
9457 extern int fchmod (int __fd, __mode_t __mode) __attribute__ ((__nothrow__ ));
\r
9463 extern int fchmodat (int __fd, const char *__file, __mode_t __mode,
\r
9465 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2))) ;
\r
9472 extern __mode_t umask (__mode_t __mask) __attribute__ ((__nothrow__ ));
\r
9473 # 321 "/usr/include/x86_64-linux-gnu/sys/stat.h" 3 4
\r
9474 extern int mkdir (const char *__path, __mode_t __mode)
\r
9475 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
9481 extern int mkdirat (int __fd, const char *__path, __mode_t __mode)
\r
9482 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2)));
\r
9489 extern int mknod (const char *__path, __mode_t __mode, __dev_t __dev)
\r
9490 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
9496 extern int mknodat (int __fd, const char *__path, __mode_t __mode,
\r
9497 __dev_t __dev) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2)));
\r
9503 extern int mkfifo (const char *__path, __mode_t __mode)
\r
9504 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (1)));
\r
9510 extern int mkfifoat (int __fd, const char *__path, __mode_t __mode)
\r
9511 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2)));
\r
9517 extern int utimensat (int __fd, const char *__path,
\r
9518 const struct timespec __times[2],
\r
9520 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2)));
\r
9525 extern int futimens (int __fd, const struct timespec __times[2]) __attribute__ ((__nothrow__ ));
\r
9526 # 399 "/usr/include/x86_64-linux-gnu/sys/stat.h" 3 4
\r
9527 extern int __fxstat (int __ver, int __fildes, struct stat *__stat_buf)
\r
9528 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (3)));
\r
9529 extern int __xstat (int __ver, const char *__filename,
\r
9530 struct stat *__stat_buf) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2, 3)));
\r
9531 extern int __lxstat (int __ver, const char *__filename,
\r
9532 struct stat *__stat_buf) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2, 3)));
\r
9533 extern int __fxstatat (int __ver, int __fildes, const char *__filename,
\r
9534 struct stat *__stat_buf, int __flag)
\r
9535 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (3, 4)));
\r
9536 # 442 "/usr/include/x86_64-linux-gnu/sys/stat.h" 3 4
\r
9537 extern int __xmknod (int __ver, const char *__path, __mode_t __mode,
\r
9538 __dev_t *__dev) __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (2, 4)));
\r
9540 extern int __xmknodat (int __ver, int __fd, const char *__path,
\r
9541 __mode_t __mode, __dev_t *__dev)
\r
9542 __attribute__ ((__nothrow__ )) __attribute__ ((__nonnull__ (3, 5)));
\r
9543 # 54 "../include/arch/unix/apr_arch_file_io.h" 2
\r
9544 # 75 "../include/arch/unix/apr_arch_file_io.h"
\r
9545 # 1 "/usr/include/x86_64-linux-gnu/sys/param.h" 1 3 4
\r
9546 # 23 "/usr/include/x86_64-linux-gnu/sys/param.h" 3 4
\r
9547 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stddef.h" 1 3 4
\r
9548 # 24 "/usr/include/x86_64-linux-gnu/sys/param.h" 2 3 4
\r
9556 # 1 "/usr/include/x86_64-linux-gnu/bits/param.h" 1 3 4
\r
9557 # 28 "/usr/include/x86_64-linux-gnu/bits/param.h" 3 4
\r
9558 # 1 "/usr/include/linux/param.h" 1 3 4
\r
9562 # 1 "/usr/include/x86_64-linux-gnu/asm/param.h" 1 3 4
\r
9563 # 1 "/usr/include/asm-generic/param.h" 1 3 4
\r
9564 # 2 "/usr/include/x86_64-linux-gnu/asm/param.h" 2 3 4
\r
9565 # 5 "/usr/include/linux/param.h" 2 3 4
\r
9566 # 29 "/usr/include/x86_64-linux-gnu/bits/param.h" 2 3 4
\r
9567 # 32 "/usr/include/x86_64-linux-gnu/sys/param.h" 2 3 4
\r
9568 # 76 "../include/arch/unix/apr_arch_file_io.h" 2
\r
9569 # 93 "../include/arch/unix/apr_arch_file_io.h"
\r
9570 struct apr_file_t {
\r
9574 apr_int32_t flags;
\r
9577 apr_interval_time_t timeout;
\r
9579 enum {BLK_UNKNOWN, BLK_OFF, BLK_ON } blocking;
\r
9587 apr_size_t bufpos;
\r
9588 apr_size_t bufsize;
\r
9589 unsigned long dataRead;
\r
9591 apr_off_t filePtr;
\r
9593 struct apr_thread_mutex_t *thlock;
\r
9596 # 142 "../include/arch/unix/apr_arch_file_io.h"
\r
9597 typedef struct stat struct_stat;
\r
9598 # 151 "../include/arch/unix/apr_arch_file_io.h"
\r
9599 struct apr_dir_t {
\r
9606 struct dirent *entry;
\r
9610 apr_status_t apr_unix_file_cleanup(void *);
\r
9611 apr_status_t apr_unix_child_file_cleanup(void *);
\r
9613 mode_t apr_unix_perms2mode(apr_fileperms_t perms);
\r
9614 apr_fileperms_t apr_unix_mode2perms(mode_t mode);
\r
9616 apr_status_t apr_file_flush_locked(apr_file_t *thefile);
\r
9617 apr_status_t apr_file_info_get_locked(apr_finfo_t *finfo, apr_int32_t wanted,
\r
9618 apr_file_t *thefile);
\r
9619 # 29 "../include/arch/unix/apr_arch_proc_mutex.h" 2
\r
9620 # 42 "../include/arch/unix/apr_arch_proc_mutex.h"
\r
9621 # 1 "/usr/include/x86_64-linux-gnu/sys/ipc.h" 1 3 4
\r
9622 # 28 "/usr/include/x86_64-linux-gnu/sys/ipc.h" 3 4
\r
9623 # 1 "/usr/include/x86_64-linux-gnu/bits/ipctypes.h" 1 3 4
\r
9624 # 28 "/usr/include/x86_64-linux-gnu/bits/ipctypes.h" 3 4
\r
9625 typedef int __ipc_pid_t;
\r
9626 # 29 "/usr/include/x86_64-linux-gnu/sys/ipc.h" 2 3 4
\r
9627 # 1 "/usr/include/x86_64-linux-gnu/bits/ipc.h" 1 3 4
\r
9628 # 42 "/usr/include/x86_64-linux-gnu/bits/ipc.h" 3 4
\r
9636 unsigned short int mode;
\r
9637 unsigned short int __pad1;
\r
9638 unsigned short int __seq;
\r
9639 unsigned short int __pad2;
\r
9640 __syscall_ulong_t __glibc_reserved1;
\r
9641 __syscall_ulong_t __glibc_reserved2;
\r
9643 # 30 "/usr/include/x86_64-linux-gnu/sys/ipc.h" 2 3 4
\r
9644 # 54 "/usr/include/x86_64-linux-gnu/sys/ipc.h" 3 4
\r
9645 extern key_t ftok (const char *__pathname, int __proj_id) __attribute__ ((__nothrow__ ));
\r
9646 # 43 "../include/arch/unix/apr_arch_proc_mutex.h" 2
\r
9649 # 1 "/usr/include/x86_64-linux-gnu/sys/sem.h" 1 3 4
\r
9650 # 24 "/usr/include/x86_64-linux-gnu/sys/sem.h" 3 4
\r
9651 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stddef.h" 1 3 4
\r
9652 # 25 "/usr/include/x86_64-linux-gnu/sys/sem.h" 2 3 4
\r
9658 # 1 "/usr/include/x86_64-linux-gnu/bits/sem.h" 1 3 4
\r
9659 # 38 "/usr/include/x86_64-linux-gnu/bits/sem.h" 3 4
\r
9662 struct ipc_perm sem_perm;
\r
9663 __time_t sem_otime;
\r
9664 __syscall_ulong_t __glibc_reserved1;
\r
9665 __time_t sem_ctime;
\r
9666 __syscall_ulong_t __glibc_reserved2;
\r
9667 __syscall_ulong_t sem_nsems;
\r
9668 __syscall_ulong_t __glibc_reserved3;
\r
9669 __syscall_ulong_t __glibc_reserved4;
\r
9671 # 72 "/usr/include/x86_64-linux-gnu/bits/sem.h" 3 4
\r
9685 # 31 "/usr/include/x86_64-linux-gnu/sys/sem.h" 2 3 4
\r
9686 # 41 "/usr/include/x86_64-linux-gnu/sys/sem.h" 3 4
\r
9689 unsigned short int sem_num;
\r
9691 short int sem_flg;
\r
9698 extern int semctl (int __semid, int __semnum, int __cmd, ...) __attribute__ ((__nothrow__ ));
\r
9701 extern int semget (key_t __key, int __nsems, int __semflg) __attribute__ ((__nothrow__ ));
\r
9704 extern int semop (int __semid, struct sembuf *__sops, size_t __nsops) __attribute__ ((__nothrow__ ));
\r
9705 # 46 "../include/arch/unix/apr_arch_proc_mutex.h" 2
\r
9708 # 1 "/usr/include/x86_64-linux-gnu/sys/file.h" 1 3 4
\r
9709 # 50 "/usr/include/x86_64-linux-gnu/sys/file.h" 3 4
\r
9710 extern int flock (int __fd, int __operation) __attribute__ ((__nothrow__ ));
\r
9711 # 49 "../include/arch/unix/apr_arch_proc_mutex.h" 2
\r
9712 # 60 "../include/arch/unix/apr_arch_proc_mutex.h"
\r
9713 # 1 "/usr/include/x86_64-linux-gnu/sys/mman.h" 1 3 4
\r
9714 # 25 "/usr/include/x86_64-linux-gnu/sys/mman.h" 3 4
\r
9715 # 1 "/usr/lib/llvm-3.5/bin/../lib/clang/3.5.0/include/stddef.h" 1 3 4
\r
9716 # 26 "/usr/include/x86_64-linux-gnu/sys/mman.h" 2 3 4
\r
9717 # 41 "/usr/include/x86_64-linux-gnu/sys/mman.h" 3 4
\r
9718 # 1 "/usr/include/x86_64-linux-gnu/bits/mman.h" 1 3 4
\r
9719 # 45 "/usr/include/x86_64-linux-gnu/bits/mman.h" 3 4
\r
9720 # 1 "/usr/include/x86_64-linux-gnu/bits/mman-linux.h" 1 3 4
\r
9721 # 46 "/usr/include/x86_64-linux-gnu/bits/mman.h" 2 3 4
\r
9722 # 42 "/usr/include/x86_64-linux-gnu/sys/mman.h" 2 3 4
\r
9723 # 57 "/usr/include/x86_64-linux-gnu/sys/mman.h" 3 4
\r
9724 extern void *mmap (void *__addr, size_t __len, int __prot,
\r
9725 int __flags, int __fd, __off_t __offset) __attribute__ ((__nothrow__ ));
\r
9726 # 76 "/usr/include/x86_64-linux-gnu/sys/mman.h" 3 4
\r
9727 extern int munmap (void *__addr, size_t __len) __attribute__ ((__nothrow__ ));
\r
9732 extern int mprotect (void *__addr, size_t __len, int __prot) __attribute__ ((__nothrow__ ));
\r
9740 extern int msync (void *__addr, size_t __len, int __flags);
\r
9745 extern int madvise (void *__addr, size_t __len, int __advice) __attribute__ ((__nothrow__ ));
\r
9749 extern int posix_madvise (void *__addr, size_t __len, int __advice) __attribute__ ((__nothrow__ ));
\r
9754 extern int mlock (const void *__addr, size_t __len) __attribute__ ((__nothrow__ ));
\r
9757 extern int munlock (const void *__addr, size_t __len) __attribute__ ((__nothrow__ ));
\r
9762 extern int mlockall (int __flags) __attribute__ ((__nothrow__ ));
\r
9766 extern int munlockall (void) __attribute__ ((__nothrow__ ));
\r
9774 extern int mincore (void *__start, size_t __len, unsigned char *__vec)
\r
9775 __attribute__ ((__nothrow__ ));
\r
9776 # 144 "/usr/include/x86_64-linux-gnu/sys/mman.h" 3 4
\r
9777 extern int shm_open (const char *__name, int __oflag, mode_t __mode);
\r
9780 extern int shm_unlink (const char *__name);
\r
9781 # 61 "../include/arch/unix/apr_arch_proc_mutex.h" 2
\r
9787 # 1 "/usr/include/semaphore.h" 1 3 4
\r
9788 # 29 "/usr/include/semaphore.h" 3 4
\r
9789 # 1 "/usr/include/x86_64-linux-gnu/bits/semaphore.h" 1 3 4
\r
9790 # 23 "/usr/include/x86_64-linux-gnu/bits/semaphore.h" 3 4
\r
9791 # 1 "/usr/include/x86_64-linux-gnu/bits/wordsize.h" 1 3 4
\r
9792 # 24 "/usr/include/x86_64-linux-gnu/bits/semaphore.h" 2 3 4
\r
9793 # 36 "/usr/include/x86_64-linux-gnu/bits/semaphore.h" 3 4
\r
9799 # 30 "/usr/include/semaphore.h" 2 3 4
\r
9806 extern int sem_init (sem_t *__sem, int __pshared, unsigned int __value)
\r
9807 __attribute__ ((__nothrow__ ));
\r
9809 extern int sem_destroy (sem_t *__sem) __attribute__ ((__nothrow__ ));
\r
9812 extern sem_t *sem_open (const char *__name, int __oflag, ...) __attribute__ ((__nothrow__ ));
\r
9815 extern int sem_close (sem_t *__sem) __attribute__ ((__nothrow__ ));
\r
9818 extern int sem_unlink (const char *__name) __attribute__ ((__nothrow__ ));
\r
9824 extern int sem_wait (sem_t *__sem);
\r
9831 extern int sem_timedwait (sem_t *__restrict __sem,
\r
9832 const struct timespec *__restrict __abstime);
\r
9836 extern int sem_trywait (sem_t *__sem) __attribute__ ((__nothrow__));
\r
9839 extern int sem_post (sem_t *__sem) __attribute__ ((__nothrow__));
\r
9842 extern int sem_getvalue (sem_t *__restrict __sem, int *__restrict __sval)
\r
9843 __attribute__ ((__nothrow__ ));
\r
9844 # 67 "../include/arch/unix/apr_arch_proc_mutex.h" 2
\r
9848 struct apr_proc_mutex_unix_lock_methods_t {
\r
9849 unsigned int flags;
\r
9850 apr_status_t (*create)(apr_proc_mutex_t *, const char *);
\r
9851 apr_status_t (*acquire)(apr_proc_mutex_t *);
\r
9852 apr_status_t (*tryacquire)(apr_proc_mutex_t *);
\r
9853 apr_status_t (*release)(apr_proc_mutex_t *);
\r
9854 apr_status_t (*cleanup)(void *);
\r
9855 apr_status_t (*child_init)(apr_proc_mutex_t **, apr_pool_t *, const char *);
\r
9858 typedef struct apr_proc_mutex_unix_lock_methods_t apr_proc_mutex_unix_lock_methods_t;
\r
9866 struct semid_ds *buf;
\r
9867 unsigned short *array;
\r
9871 struct apr_proc_mutex_t {
\r
9873 const apr_proc_mutex_unix_lock_methods_t *meth;
\r
9874 const apr_proc_mutex_unix_lock_methods_t *inter_meth;
\r
9878 apr_file_t *interproc;
\r
9881 sem_t *psem_interproc;
\r
9884 pthread_mutex_t *pthread_interproc;
\r
9888 void apr_proc_mutex_unix_setup_lock(void);
\r
9889 # 20 "./../locks/unix/proc_mutex.c" 2
\r
9891 # 1 "../include/apr_hash.h" 1
\r
9892 # 52 "../include/apr_hash.h"
\r
9893 typedef struct apr_hash_t apr_hash_t;
\r
9898 typedef struct apr_hash_index_t apr_hash_index_t;
\r
9906 typedef unsigned int (*apr_hashfunc_t)(const char *key, apr_ssize_t *klen);
\r
9911 unsigned int apr_hashfunc_default(const char *key,
\r
9912 apr_ssize_t *klen);
\r
9919 apr_hash_t * apr_hash_make(apr_pool_t *pool);
\r
9927 apr_hash_t * apr_hash_make_custom(apr_pool_t *pool,
\r
9928 apr_hashfunc_t hash_func);
\r
9929 # 96 "../include/apr_hash.h"
\r
9930 apr_hash_t * apr_hash_copy(apr_pool_t *pool,
\r
9931 const apr_hash_t *h);
\r
9932 # 107 "../include/apr_hash.h"
\r
9933 void apr_hash_set(apr_hash_t *ht, const void *key,
\r
9934 apr_ssize_t klen, const void *val);
\r
9935 # 117 "../include/apr_hash.h"
\r
9936 void * apr_hash_get(apr_hash_t *ht, const void *key,
\r
9937 apr_ssize_t klen);
\r
9938 # 147 "../include/apr_hash.h"
\r
9939 apr_hash_index_t * apr_hash_first(apr_pool_t *p, apr_hash_t *ht);
\r
9947 apr_hash_index_t * apr_hash_next(apr_hash_index_t *hi);
\r
9948 # 166 "../include/apr_hash.h"
\r
9949 void apr_hash_this(apr_hash_index_t *hi, const void **key,
\r
9950 apr_ssize_t *klen, void **val);
\r
9957 const void* apr_hash_this_key(apr_hash_index_t *hi);
\r
9964 apr_ssize_t apr_hash_this_key_len(apr_hash_index_t *hi);
\r
9971 void* apr_hash_this_val(apr_hash_index_t *hi);
\r
9978 unsigned int apr_hash_count(apr_hash_t *ht);
\r
9984 void apr_hash_clear(apr_hash_t *ht);
\r
9985 # 212 "../include/apr_hash.h"
\r
9986 apr_hash_t * apr_hash_overlay(apr_pool_t *p,
\r
9987 const apr_hash_t *overlay,
\r
9988 const apr_hash_t *base);
\r
9989 # 230 "../include/apr_hash.h"
\r
9990 apr_hash_t * apr_hash_merge(apr_pool_t *p,
\r
9991 const apr_hash_t *h1,
\r
9992 const apr_hash_t *h2,
\r
9993 void * (*merger)(apr_pool_t *p,
\r
9996 const void *h1_val,
\r
9997 const void *h2_val,
\r
9998 const void *data),
\r
9999 const void *data);
\r
10000 # 252 "../include/apr_hash.h"
\r
10001 typedef int (apr_hash_do_callback_fn_t)(void *rec, const void *key,
\r
10002 apr_ssize_t klen,
\r
10003 const void *value);
\r
10004 # 268 "../include/apr_hash.h"
\r
10005 int apr_hash_do(apr_hash_do_callback_fn_t *comp,
\r
10006 void *rec, const apr_hash_t *ht);
\r
10011 apr_pool_t * apr_hash_pool_get (const apr_hash_t *thehash);
\r
10012 # 22 "./../locks/unix/proc_mutex.c" 2
\r
10014 apr_status_t apr_proc_mutex_destroy(apr_proc_mutex_t *mutex)
\r
10016 return apr_pool_cleanup_run(mutex->pool, mutex, apr_proc_mutex_cleanup);
\r
10021 static apr_status_t proc_mutex_no_child_init(apr_proc_mutex_t **mutex,
\r
10022 apr_pool_t *cont,
\r
10023 const char *fname)
\r
10027 # 44 "./../locks/unix/proc_mutex.c"
\r
10028 static apr_status_t proc_mutex_posix_cleanup(void *mutex_)
\r
10030 apr_proc_mutex_t *mutex = mutex_;
\r
10032 if (sem_close(mutex->psem_interproc) < 0) {
\r
10033 return (*__errno_location ());
\r
10039 static unsigned int rshash (char *p) {
\r
10041 unsigned int b = 378551;
\r
10042 unsigned int a = 63689;
\r
10043 unsigned int retval = 0;
\r
10047 retval = retval * a + (*p);
\r
10054 static apr_status_t proc_mutex_posix_create(apr_proc_mutex_t *new_mutex,
\r
10055 const char *fname)
\r
10059 char semname[32];
\r
10061 new_mutex->interproc = apr_palloc(new_mutex->pool,
\r
10062 sizeof(*new_mutex->interproc));
\r
10063 # 101 "./../locks/unix/proc_mutex.c"
\r
10065 apr_ssize_t flen = strlen(fname);
\r
10066 char *p = apr_pstrndup(new_mutex->pool, fname, strlen(fname));
\r
10067 unsigned int h1, h2;
\r
10068 h1 = (apr_hashfunc_default((const char *)p, &flen) & 0xffffffff);
\r
10069 h2 = (rshash(p) & 0xffffffff);
\r
10070 apr_snprintf(semname, sizeof(semname), "/ApR.%xH%x", h1, h2);
\r
10073 unsigned long sec;
\r
10074 unsigned long usec;
\r
10075 now = apr_time_now();
\r
10076 sec = ((now) / 1000000L);
\r
10077 usec = ((now) % 1000000L);
\r
10078 apr_snprintf(semname, sizeof(semname), "/ApR.%lxZ%lx", sec, usec);
\r
10080 psem = sem_open(semname, 0100 | 0200, 0644, 1);
\r
10081 if (psem == (sem_t *)((sem_t *) 0)) {
\r
10082 if ((*__errno_location ()) == 36) {
\r
10084 semname[13] = '\0';
\r
10086 return (*__errno_location ());
\r
10088 psem = sem_open(semname, 0100 | 0200, 0644, 1);
\r
10091 if (psem == (sem_t *)((sem_t *) 0)) {
\r
10092 return (*__errno_location ());
\r
10095 sem_unlink(semname);
\r
10096 new_mutex->psem_interproc = psem;
\r
10097 new_mutex->fname = apr_pstrdup(new_mutex->pool, semname);
\r
10098 apr_pool_cleanup_register(new_mutex->pool, (void *)new_mutex,
\r
10099 apr_proc_mutex_cleanup,
\r
10100 apr_pool_cleanup_null);
\r
10104 static apr_status_t proc_mutex_posix_acquire(apr_proc_mutex_t *mutex)
\r
10106 if (sem_wait(mutex->psem_interproc) < 0) {
\r
10107 return (*__errno_location ());
\r
10109 mutex->curr_locked = 1;
\r
10113 static apr_status_t proc_mutex_posix_tryacquire(apr_proc_mutex_t *mutex)
\r
10115 if (sem_trywait(mutex->psem_interproc) < 0) {
\r
10116 if ((*__errno_location ()) == 11) {
\r
10117 return ((20000 + 50000) + 25);
\r
10119 return (*__errno_location ());
\r
10121 mutex->curr_locked = 1;
\r
10125 static apr_status_t proc_mutex_posix_release(apr_proc_mutex_t *mutex)
\r
10127 mutex->curr_locked = 0;
\r
10128 if (sem_post(mutex->psem_interproc) < 0) {
\r
10131 return (*__errno_location ());
\r
10136 static const apr_proc_mutex_unix_lock_methods_t mutex_posixsem_methods =
\r
10143 proc_mutex_posix_create,
\r
10144 proc_mutex_posix_acquire,
\r
10145 proc_mutex_posix_tryacquire,
\r
10146 proc_mutex_posix_release,
\r
10147 proc_mutex_posix_cleanup,
\r
10148 proc_mutex_no_child_init,
\r
10156 static struct sembuf proc_mutex_op_on;
\r
10157 static struct sembuf proc_mutex_op_try;
\r
10158 static struct sembuf proc_mutex_op_off;
\r
10160 static void proc_mutex_sysv_setup(void)
\r
10162 proc_mutex_op_on.sem_num = 0;
\r
10163 proc_mutex_op_on.sem_op = -1;
\r
10164 proc_mutex_op_on.sem_flg = 0x1000;
\r
10165 proc_mutex_op_try.sem_num = 0;
\r
10166 proc_mutex_op_try.sem_op = -1;
\r
10167 proc_mutex_op_try.sem_flg = 0x1000 | 04000;
\r
10168 proc_mutex_op_off.sem_num = 0;
\r
10169 proc_mutex_op_off.sem_op = 1;
\r
10170 proc_mutex_op_off.sem_flg = 0x1000;
\r
10173 static apr_status_t proc_mutex_sysv_cleanup(void *mutex_)
\r
10175 apr_proc_mutex_t *mutex=mutex_;
\r
10178 if (mutex->interproc->filedes != -1) {
\r
10180 semctl(mutex->interproc->filedes, 0, 0, ick);
\r
10185 static apr_status_t proc_mutex_sysv_create(apr_proc_mutex_t *new_mutex,
\r
10186 const char *fname)
\r
10191 new_mutex->interproc = apr_palloc(new_mutex->pool, sizeof(*new_mutex->interproc));
\r
10192 new_mutex->interproc->filedes = semget(((__key_t) 0), 1, 01000 | 0600);
\r
10194 if (new_mutex->interproc->filedes < 0) {
\r
10195 rv = (*__errno_location ());
\r
10196 proc_mutex_sysv_cleanup(new_mutex);
\r
10200 if (semctl(new_mutex->interproc->filedes, 0, 16, ick) < 0) {
\r
10201 rv = (*__errno_location ());
\r
10202 proc_mutex_sysv_cleanup(new_mutex);
\r
10205 new_mutex->curr_locked = 0;
\r
10206 apr_pool_cleanup_register(new_mutex->pool,
\r
10207 (void *)new_mutex, apr_proc_mutex_cleanup,
\r
10208 apr_pool_cleanup_null);
\r
10212 static apr_status_t proc_mutex_sysv_acquire(apr_proc_mutex_t *mutex)
\r
10217 rc = semop(mutex->interproc->filedes, &proc_mutex_op_on, 1);
\r
10218 } while (rc < 0 && (*__errno_location ()) == 4);
\r
10220 return (*__errno_location ());
\r
10222 mutex->curr_locked = 1;
\r
10226 static apr_status_t proc_mutex_sysv_tryacquire(apr_proc_mutex_t *mutex)
\r
10231 rc = semop(mutex->interproc->filedes, &proc_mutex_op_try, 1);
\r
10232 } while (rc < 0 && (*__errno_location ()) == 4);
\r
10234 if ((*__errno_location ()) == 11) {
\r
10235 return ((20000 + 50000) + 25);
\r
10237 return (*__errno_location ());
\r
10239 mutex->curr_locked = 1;
\r
10243 static apr_status_t proc_mutex_sysv_release(apr_proc_mutex_t *mutex)
\r
10247 mutex->curr_locked = 0;
\r
10249 rc = semop(mutex->interproc->filedes, &proc_mutex_op_off, 1);
\r
10250 } while (rc < 0 && (*__errno_location ()) == 4);
\r
10252 return (*__errno_location ());
\r
10257 static const apr_proc_mutex_unix_lock_methods_t mutex_sysv_methods =
\r
10264 proc_mutex_sysv_create,
\r
10265 proc_mutex_sysv_acquire,
\r
10266 proc_mutex_sysv_tryacquire,
\r
10267 proc_mutex_sysv_release,
\r
10268 proc_mutex_sysv_cleanup,
\r
10269 proc_mutex_no_child_init,
\r
10277 static apr_status_t proc_mutex_proc_pthread_cleanup(void *mutex_)
\r
10279 apr_proc_mutex_t *mutex=mutex_;
\r
10282 if (mutex->curr_locked == 1) {
\r
10283 if ((rv = pthread_mutex_unlock(mutex->pthread_interproc))) {
\r
10291 if (mutex->curr_locked != -1) {
\r
10292 if ((rv = pthread_mutex_destroy(mutex->pthread_interproc))) {
\r
10299 if (munmap((caddr_t)mutex->pthread_interproc, sizeof(pthread_mutex_t))) {
\r
10300 return (*__errno_location ());
\r
10305 static apr_status_t proc_mutex_proc_pthread_create(apr_proc_mutex_t *new_mutex,
\r
10306 const char *fname)
\r
10310 pthread_mutexattr_t mattr;
\r
10312 fd = open("/dev/zero", 02);
\r
10314 return (*__errno_location ());
\r
10317 new_mutex->pthread_interproc = (pthread_mutex_t *)mmap(
\r
10319 sizeof(pthread_mutex_t),
\r
10322 if (new_mutex->pthread_interproc == (pthread_mutex_t *) (caddr_t) -1) {
\r
10324 return (*__errno_location ());
\r
10328 new_mutex->curr_locked = -1;
\r
10330 if ((rv = pthread_mutexattr_init(&mattr))) {
\r
10334 proc_mutex_proc_pthread_cleanup(new_mutex);
\r
10337 if ((rv = pthread_mutexattr_setpshared(&mattr, PTHREAD_PROCESS_SHARED))) {
\r
10341 proc_mutex_proc_pthread_cleanup(new_mutex);
\r
10342 pthread_mutexattr_destroy(&mattr);
\r
10347 if ((rv = pthread_mutexattr_setrobust_np(&mattr,
\r
10348 PTHREAD_MUTEX_ROBUST_NP))) {
\r
10352 proc_mutex_proc_pthread_cleanup(new_mutex);
\r
10353 pthread_mutexattr_destroy(&mattr);
\r
10356 if ((rv = pthread_mutexattr_setprotocol(&mattr, PTHREAD_PRIO_INHERIT))) {
\r
10360 proc_mutex_proc_pthread_cleanup(new_mutex);
\r
10361 pthread_mutexattr_destroy(&mattr);
\r
10366 if ((rv = pthread_mutex_init(new_mutex->pthread_interproc, &mattr))) {
\r
10370 proc_mutex_proc_pthread_cleanup(new_mutex);
\r
10371 pthread_mutexattr_destroy(&mattr);
\r
10375 new_mutex->curr_locked = 0;
\r
10377 if ((rv = pthread_mutexattr_destroy(&mattr))) {
\r
10381 proc_mutex_proc_pthread_cleanup(new_mutex);
\r
10385 apr_pool_cleanup_register(new_mutex->pool,
\r
10386 (void *)new_mutex,
\r
10387 apr_proc_mutex_cleanup,
\r
10388 apr_pool_cleanup_null);
\r
10392 static apr_status_t proc_mutex_proc_pthread_acquire(apr_proc_mutex_t *mutex)
\r
10396 if ((rv = pthread_mutex_lock(mutex->pthread_interproc))) {
\r
10403 pthread_mutex_consistent_np(mutex->pthread_interproc);
\r
10411 mutex->curr_locked = 1;
\r
10415 static apr_status_t proc_mutex_proc_pthread_tryacquire(apr_proc_mutex_t *mutex)
\r
10419 if ((rv = pthread_mutex_trylock(mutex->pthread_interproc))) {
\r
10424 return ((20000 + 50000) + 25);
\r
10429 pthread_mutex_consistent_np(mutex->pthread_interproc);
\r
10438 mutex->curr_locked = 1;
\r
10442 static apr_status_t proc_mutex_proc_pthread_release(apr_proc_mutex_t *mutex)
\r
10446 mutex->curr_locked = 0;
\r
10447 if ((rv = pthread_mutex_unlock(mutex->pthread_interproc))) {
\r
10456 static const apr_proc_mutex_unix_lock_methods_t mutex_proc_pthread_methods =
\r
10459 proc_mutex_proc_pthread_create,
\r
10460 proc_mutex_proc_pthread_acquire,
\r
10461 proc_mutex_proc_pthread_tryacquire,
\r
10462 proc_mutex_proc_pthread_release,
\r
10463 proc_mutex_proc_pthread_cleanup,
\r
10464 proc_mutex_no_child_init,
\r
10472 static struct flock proc_mutex_lock_it;
\r
10473 static struct flock proc_mutex_unlock_it;
\r
10475 static apr_status_t proc_mutex_fcntl_release(apr_proc_mutex_t *);
\r
10477 static void proc_mutex_fcntl_setup(void)
\r
10479 proc_mutex_lock_it.l_whence = 0;
\r
10480 proc_mutex_lock_it.l_start = 0;
\r
10481 proc_mutex_lock_it.l_len = 0;
\r
10482 proc_mutex_lock_it.l_type = 1;
\r
10483 proc_mutex_lock_it.l_pid = 0;
\r
10484 proc_mutex_unlock_it.l_whence = 0;
\r
10485 proc_mutex_unlock_it.l_start = 0;
\r
10486 proc_mutex_unlock_it.l_len = 0;
\r
10487 proc_mutex_unlock_it.l_type = 2;
\r
10488 proc_mutex_unlock_it.l_pid = 0;
\r
10491 static apr_status_t proc_mutex_fcntl_cleanup(void *mutex_)
\r
10493 apr_status_t status;
\r
10494 apr_proc_mutex_t *mutex=mutex_;
\r
10496 if (mutex->curr_locked == 1) {
\r
10497 status = proc_mutex_fcntl_release(mutex);
\r
10502 return apr_file_close(mutex->interproc);
\r
10505 static apr_status_t proc_mutex_fcntl_create(apr_proc_mutex_t *new_mutex,
\r
10506 const char *fname)
\r
10511 new_mutex->fname = apr_pstrdup(new_mutex->pool, fname);
\r
10512 rv = apr_file_open(&new_mutex->interproc, new_mutex->fname,
\r
10513 0x00004 | 0x00002 | 0x00040,
\r
10514 0x0400 | 0x0200 | 0x0040 | 0x0004,
\r
10515 new_mutex->pool);
\r
10518 new_mutex->fname = apr_pstrdup(new_mutex->pool, "/tmp/aprXXXXXX");
\r
10519 rv = apr_file_mktemp(&new_mutex->interproc, new_mutex->fname,
\r
10520 0x00004 | 0x00002 | 0x00040,
\r
10521 new_mutex->pool);
\r
10528 new_mutex->curr_locked = 0;
\r
10529 unlink(new_mutex->fname);
\r
10530 apr_pool_cleanup_register(new_mutex->pool,
\r
10531 (void*)new_mutex,
\r
10532 apr_proc_mutex_cleanup,
\r
10533 apr_pool_cleanup_null);
\r
10537 static apr_status_t proc_mutex_fcntl_acquire(apr_proc_mutex_t *mutex)
\r
10542 rc = fcntl(mutex->interproc->filedes, 7, &proc_mutex_lock_it);
\r
10543 } while (rc < 0 && (*__errno_location ()) == 4);
\r
10545 return (*__errno_location ());
\r
10547 mutex->curr_locked=1;
\r
10551 static apr_status_t proc_mutex_fcntl_tryacquire(apr_proc_mutex_t *mutex)
\r
10556 rc = fcntl(mutex->interproc->filedes, 6, &proc_mutex_lock_it);
\r
10557 } while (rc < 0 && (*__errno_location ()) == 4);
\r
10562 if ((*__errno_location ()) == 11) {
\r
10564 return ((20000 + 50000) + 25);
\r
10566 return (*__errno_location ());
\r
10568 mutex->curr_locked = 1;
\r
10572 static apr_status_t proc_mutex_fcntl_release(apr_proc_mutex_t *mutex)
\r
10576 mutex->curr_locked=0;
\r
10578 rc = fcntl(mutex->interproc->filedes, 7, &proc_mutex_unlock_it);
\r
10579 } while (rc < 0 && (*__errno_location ()) == 4);
\r
10581 return (*__errno_location ());
\r
10586 static const apr_proc_mutex_unix_lock_methods_t mutex_fcntl_methods =
\r
10593 proc_mutex_fcntl_create,
\r
10594 proc_mutex_fcntl_acquire,
\r
10595 proc_mutex_fcntl_tryacquire,
\r
10596 proc_mutex_fcntl_release,
\r
10597 proc_mutex_fcntl_cleanup,
\r
10598 proc_mutex_no_child_init,
\r
10606 static apr_status_t proc_mutex_flock_release(apr_proc_mutex_t *);
\r
10608 static apr_status_t proc_mutex_flock_cleanup(void *mutex_)
\r
10610 apr_status_t status;
\r
10611 apr_proc_mutex_t *mutex=mutex_;
\r
10613 if (mutex->curr_locked == 1) {
\r
10614 status = proc_mutex_flock_release(mutex);
\r
10618 if (mutex->interproc) {
\r
10619 apr_file_close(mutex->interproc);
\r
10621 unlink(mutex->fname);
\r
10625 static apr_status_t proc_mutex_flock_create(apr_proc_mutex_t *new_mutex,
\r
10626 const char *fname)
\r
10631 new_mutex->fname = apr_pstrdup(new_mutex->pool, fname);
\r
10632 rv = apr_file_open(&new_mutex->interproc, new_mutex->fname,
\r
10633 0x00004 | 0x00002 | 0x00040,
\r
10635 new_mutex->pool);
\r
10638 new_mutex->fname = apr_pstrdup(new_mutex->pool, "/tmp/aprXXXXXX");
\r
10639 rv = apr_file_mktemp(&new_mutex->interproc, new_mutex->fname,
\r
10640 0x00004 | 0x00002 | 0x00040,
\r
10641 new_mutex->pool);
\r
10645 proc_mutex_flock_cleanup(new_mutex);
\r
10646 return (*__errno_location ());
\r
10648 new_mutex->curr_locked = 0;
\r
10649 apr_pool_cleanup_register(new_mutex->pool, (void *)new_mutex,
\r
10650 apr_proc_mutex_cleanup,
\r
10651 apr_pool_cleanup_null);
\r
10655 static apr_status_t proc_mutex_flock_acquire(apr_proc_mutex_t *mutex)
\r
10660 rc = flock(mutex->interproc->filedes, 2);
\r
10661 } while (rc < 0 && (*__errno_location ()) == 4);
\r
10663 return (*__errno_location ());
\r
10665 mutex->curr_locked = 1;
\r
10669 static apr_status_t proc_mutex_flock_tryacquire(apr_proc_mutex_t *mutex)
\r
10674 rc = flock(mutex->interproc->filedes, 2 | 4);
\r
10675 } while (rc < 0 && (*__errno_location ()) == 4);
\r
10677 if ((*__errno_location ()) == 11 || (*__errno_location ()) == 11) {
\r
10678 return ((20000 + 50000) + 25);
\r
10680 return (*__errno_location ());
\r
10682 mutex->curr_locked = 1;
\r
10686 static apr_status_t proc_mutex_flock_release(apr_proc_mutex_t *mutex)
\r
10690 mutex->curr_locked = 0;
\r
10692 rc = flock(mutex->interproc->filedes, 8);
\r
10693 } while (rc < 0 && (*__errno_location ()) == 4);
\r
10695 return (*__errno_location ());
\r
10700 static apr_status_t proc_mutex_flock_child_init(apr_proc_mutex_t **mutex,
\r
10701 apr_pool_t *pool,
\r
10702 const char *fname)
\r
10704 apr_proc_mutex_t *new_mutex;
\r
10707 new_mutex = (apr_proc_mutex_t *)apr_palloc(pool, sizeof(apr_proc_mutex_t));
\r
10709 memcpy(new_mutex, *mutex, sizeof *new_mutex);
\r
10710 new_mutex->pool = pool;
\r
10712 fname = (*mutex)->fname;
\r
10714 new_mutex->fname = apr_pstrdup(pool, fname);
\r
10715 rv = apr_file_open(&new_mutex->interproc, new_mutex->fname,
\r
10716 0x00002, 0, new_mutex->pool);
\r
10720 *mutex = new_mutex;
\r
10724 static const apr_proc_mutex_unix_lock_methods_t mutex_flock_methods =
\r
10731 proc_mutex_flock_create,
\r
10732 proc_mutex_flock_acquire,
\r
10733 proc_mutex_flock_tryacquire,
\r
10734 proc_mutex_flock_release,
\r
10735 proc_mutex_flock_cleanup,
\r
10736 proc_mutex_flock_child_init,
\r
10742 void apr_proc_mutex_unix_setup_lock(void)
\r
10746 proc_mutex_sysv_setup();
\r
10749 proc_mutex_fcntl_setup();
\r
10753 static apr_status_t proc_mutex_choose_method(apr_proc_mutex_t *new_mutex, apr_lockmech_e mech)
\r
10756 case APR_LOCK_FCNTL:
\r
10758 new_mutex->inter_meth = &mutex_fcntl_methods;
\r
10763 case APR_LOCK_FLOCK:
\r
10765 new_mutex->inter_meth = &mutex_flock_methods;
\r
10770 case APR_LOCK_SYSVSEM:
\r
10772 new_mutex->inter_meth = &mutex_sysv_methods;
\r
10777 case APR_LOCK_POSIXSEM:
\r
10779 new_mutex->inter_meth = &mutex_posixsem_methods;
\r
10784 case APR_LOCK_PROC_PTHREAD:
\r
10786 new_mutex->inter_meth = &mutex_proc_pthread_methods;
\r
10791 case APR_LOCK_DEFAULT:
\r
10795 new_mutex->inter_meth = &mutex_sysv_methods;
\r
10796 # 842 "./../locks/unix/proc_mutex.c"
\r
10799 return ((20000 + 50000) + 23);
\r
10804 const char * apr_proc_mutex_defname(void)
\r
10807 apr_proc_mutex_t mutex;
\r
10809 if ((rv = proc_mutex_choose_method(&mutex, APR_LOCK_DEFAULT)) != 0) {
\r
10810 return "unknown";
\r
10812 mutex.meth = mutex.inter_meth;
\r
10814 return apr_proc_mutex_name(&mutex);
\r
10817 static apr_status_t proc_mutex_create(apr_proc_mutex_t *new_mutex, apr_lockmech_e mech, const char *fname)
\r
10821 if ((rv = proc_mutex_choose_method(new_mutex, mech)) != 0) {
\r
10825 new_mutex->meth = new_mutex->inter_meth;
\r
10827 if ((rv = new_mutex->meth->create(new_mutex, fname)) != 0) {
\r
10834 apr_status_t apr_proc_mutex_create(apr_proc_mutex_t **mutex,
\r
10835 const char *fname,
\r
10836 apr_lockmech_e mech,
\r
10837 apr_pool_t *pool)
\r
10839 apr_proc_mutex_t *new_mutex;
\r
10842 new_mutex = memset(apr_palloc(pool, sizeof(apr_proc_mutex_t)), 0, sizeof(apr_proc_mutex_t));
\r
10843 new_mutex->pool = pool;
\r
10845 if ((rv = proc_mutex_create(new_mutex, mech, fname)) != 0)
\r
10848 *mutex = new_mutex;
\r
10852 apr_status_t apr_proc_mutex_child_init(apr_proc_mutex_t **mutex,
\r
10853 const char *fname,
\r
10854 apr_pool_t *pool)
\r
10856 return (*mutex)->meth->child_init(mutex, pool, fname);
\r
10859 apr_status_t apr_proc_mutex_lock(apr_proc_mutex_t *mutex)
\r
10861 return mutex->meth->acquire(mutex);
\r
10864 apr_status_t apr_proc_mutex_trylock(apr_proc_mutex_t *mutex)
\r
10866 return mutex->meth->tryacquire(mutex);
\r
10869 apr_status_t apr_proc_mutex_unlock(apr_proc_mutex_t *mutex)
\r
10871 return mutex->meth->release(mutex);
\r
10874 apr_status_t apr_proc_mutex_cleanup(void *mutex)
\r
10876 return ((apr_proc_mutex_t *)mutex)->meth->cleanup(mutex);
\r
10879 const char * apr_proc_mutex_name(apr_proc_mutex_t *mutex)
\r
10881 return mutex->meth->name;
\r
10884 const char * apr_proc_mutex_lockfile(apr_proc_mutex_t *mutex)
\r
10889 if (mutex->meth == &mutex_flock_methods) {
\r
10890 return mutex->fname;
\r
10894 if (mutex->meth == &mutex_fcntl_methods) {
\r
10895 return mutex->fname;
\r
10898 return ((void*)0);
\r
10901 apr_pool_t * apr_proc_mutex_pool_get (const apr_proc_mutex_t *theproc_mutex) { return theproc_mutex->pool; }
\r
10905 apr_status_t apr_os_proc_mutex_get(apr_os_proc_mutex_t *ospmutex,
\r
10906 apr_proc_mutex_t *pmutex)
\r
10909 if (pmutex->interproc) {
\r
10910 ospmutex->crossproc = pmutex->interproc->filedes;
\r
10913 ospmutex->crossproc = -1;
\r
10917 ospmutex->pthread_interproc = pmutex->pthread_interproc;
\r
10922 apr_status_t apr_os_proc_mutex_put(apr_proc_mutex_t **pmutex,
\r
10923 apr_os_proc_mutex_t *ospmutex,
\r
10924 apr_pool_t *pool)
\r
10926 if (pool == ((void*)0)) {
\r
10927 return (20000 + 2);
\r
10929 if ((*pmutex) == ((void*)0)) {
\r
10930 (*pmutex) = (apr_proc_mutex_t *)memset(apr_palloc(pool, sizeof(apr_proc_mutex_t)), 0, sizeof(apr_proc_mutex_t));
\r
10932 (*pmutex)->pool = pool;
\r
10935 apr_os_file_put(&(*pmutex)->interproc, &ospmutex->crossproc, 0, pool);
\r
10938 (*pmutex)->pthread_interproc = ospmutex->pthread_interproc;
\r
10943 # 1 "./../memory/unix/apr_pools.c" 1
\r
10944 # 31 "./../memory/unix/apr_pools.c"
\r
10945 # 1 "../include/apr_want.h" 1
\r
10946 # 32 "./../memory/unix/apr_pools.c" 2
\r
10947 # 1 "../include/apr_env.h" 1
\r
10948 # 42 "../include/apr_env.h"
\r
10949 apr_status_t apr_env_get(char **value, const char *envvar,
\r
10950 apr_pool_t *pool);
\r
10958 apr_status_t apr_env_set(const char *envvar, const char *value,
\r
10959 apr_pool_t *pool);
\r
10966 apr_status_t apr_env_delete(const char *envvar, apr_pool_t *pool);
\r
10967 # 33 "./../memory/unix/apr_pools.c" 2
\r
10968 # 85 "./../memory/unix/apr_pools.c"
\r
10969 struct apr_allocator_t {
\r
10971 apr_uint32_t max_index;
\r
10977 apr_uint32_t max_free_index;
\r
10982 apr_uint32_t current_free_index;
\r
10984 apr_thread_mutex_t *mutex;
\r
10986 apr_pool_t *owner;
\r
10987 # 113 "./../memory/unix/apr_pools.c"
\r
10988 apr_memnode_t *free[20];
\r
10990 # 123 "./../memory/unix/apr_pools.c"
\r
10991 apr_status_t apr_allocator_create(apr_allocator_t **allocator)
\r
10993 apr_allocator_t *new_allocator;
\r
10995 *allocator = ((void*)0);
\r
10997 if ((new_allocator = malloc((((sizeof(apr_allocator_t)) + ((8) - 1)) & ~((8) - 1)))) == ((void*)0))
\r
11000 memset(new_allocator, 0, (((sizeof(apr_allocator_t)) + ((8) - 1)) & ~((8) - 1)));
\r
11001 new_allocator->max_free_index = 0;
\r
11003 *allocator = new_allocator;
\r
11008 void apr_allocator_destroy(apr_allocator_t *allocator)
\r
11010 apr_uint32_t index;
\r
11011 apr_memnode_t *node, **ref;
\r
11013 for (index = 0; index < 20; index++) {
\r
11014 ref = &allocator->free[index];
\r
11015 while ((node = *ref) != ((void*)0)) {
\r
11016 *ref = node->next;
\r
11029 void apr_allocator_mutex_set(apr_allocator_t *allocator,
\r
11030 apr_thread_mutex_t *mutex)
\r
11032 allocator->mutex = mutex;
\r
11035 apr_thread_mutex_t * apr_allocator_mutex_get(
\r
11036 apr_allocator_t *allocator)
\r
11038 return allocator->mutex;
\r
11042 void apr_allocator_owner_set(apr_allocator_t *allocator,
\r
11043 apr_pool_t *pool)
\r
11045 allocator->owner = pool;
\r
11048 apr_pool_t * apr_allocator_owner_get(apr_allocator_t *allocator)
\r
11050 return allocator->owner;
\r
11053 void apr_allocator_max_free_set(apr_allocator_t *allocator,
\r
11054 apr_size_t in_size)
\r
11056 apr_uint32_t max_free_index;
\r
11057 apr_uint32_t size = (apr_uint32_t)in_size;
\r
11060 apr_thread_mutex_t *mutex;
\r
11062 mutex = apr_allocator_mutex_get(allocator);
\r
11063 if (mutex != ((void*)0))
\r
11064 apr_thread_mutex_lock(mutex);
\r
11067 max_free_index = (((size) + (((1 << 12)) - 1)) & ~(((1 << 12)) - 1)) >> 12;
\r
11068 allocator->current_free_index += max_free_index;
\r
11069 allocator->current_free_index -= allocator->max_free_index;
\r
11070 allocator->max_free_index = max_free_index;
\r
11071 if (allocator->current_free_index > max_free_index)
\r
11072 allocator->current_free_index = max_free_index;
\r
11075 if (mutex != ((void*)0))
\r
11076 apr_thread_mutex_unlock(mutex);
\r
11080 static __inline__
\r
11081 apr_memnode_t *allocator_alloc(apr_allocator_t *allocator, apr_size_t in_size)
\r
11083 apr_memnode_t *node, **ref;
\r
11084 apr_uint32_t max_index;
\r
11085 apr_size_t size, i, index;
\r
11090 size = (((in_size + (((sizeof(apr_memnode_t)) + ((8) - 1)) & ~((8) - 1))) + (((1 << 12)) - 1)) & ~(((1 << 12)) - 1));
\r
11091 if (size < in_size) {
\r
11092 return ((void*)0);
\r
11094 if (size < (2 * (1 << 12)))
\r
11095 size = (2 * (1 << 12));
\r
11100 index = (size >> 12) - 1;
\r
11102 if (index > (4294967295U)) {
\r
11103 return ((void*)0);
\r
11109 if (index <= allocator->max_index) {
\r
11111 if (allocator->mutex)
\r
11112 apr_thread_mutex_lock(allocator->mutex);
\r
11113 # 257 "./../memory/unix/apr_pools.c"
\r
11114 max_index = allocator->max_index;
\r
11115 ref = &allocator->free[index];
\r
11117 while (*ref == ((void*)0) && i < max_index) {
\r
11122 if ((node = *ref) != ((void*)0)) {
\r
11128 if ((*ref = node->next) == ((void*)0) && i >= max_index) {
\r
11133 while (*ref == ((void*)0) && max_index > 0);
\r
11135 allocator->max_index = max_index;
\r
11138 allocator->current_free_index += node->index + 1;
\r
11139 if (allocator->current_free_index > allocator->max_free_index)
\r
11140 allocator->current_free_index = allocator->max_free_index;
\r
11143 if (allocator->mutex)
\r
11144 apr_thread_mutex_unlock(allocator->mutex);
\r
11147 node->next = ((void*)0);
\r
11148 node->first_avail = (char *)node + (((sizeof(apr_memnode_t)) + ((8) - 1)) & ~((8) - 1));
\r
11154 if (allocator->mutex)
\r
11155 apr_thread_mutex_unlock(allocator->mutex);
\r
11162 else if (allocator->free[0]) {
\r
11164 if (allocator->mutex)
\r
11165 apr_thread_mutex_lock(allocator->mutex);
\r
11171 ref = &allocator->free[0];
\r
11172 while ((node = *ref) != ((void*)0) && index > node->index)
\r
11173 ref = &node->next;
\r
11176 *ref = node->next;
\r
11178 allocator->current_free_index += node->index + 1;
\r
11179 if (allocator->current_free_index > allocator->max_free_index)
\r
11180 allocator->current_free_index = allocator->max_free_index;
\r
11183 if (allocator->mutex)
\r
11184 apr_thread_mutex_unlock(allocator->mutex);
\r
11187 node->next = ((void*)0);
\r
11188 node->first_avail = (char *)node + (((sizeof(apr_memnode_t)) + ((8) - 1)) & ~((8) - 1));
\r
11194 if (allocator->mutex)
\r
11195 apr_thread_mutex_unlock(allocator->mutex);
\r
11198 # 349 "./../memory/unix/apr_pools.c"
\r
11199 if ((node = malloc(size)) == ((void*)0))
\r
11201 return ((void*)0);
\r
11203 node->next = ((void*)0);
\r
11204 node->index = (apr_uint32_t)index;
\r
11205 node->first_avail = (char *)node + (((sizeof(apr_memnode_t)) + ((8) - 1)) & ~((8) - 1));
\r
11206 node->endp = (char *)node + size;
\r
11211 static __inline__
\r
11212 void allocator_free(apr_allocator_t *allocator, apr_memnode_t *node)
\r
11214 apr_memnode_t *next, *freelist = ((void*)0);
\r
11215 apr_uint32_t index, max_index;
\r
11216 apr_uint32_t max_free_index, current_free_index;
\r
11219 if (allocator->mutex)
\r
11220 apr_thread_mutex_lock(allocator->mutex);
\r
11223 max_index = allocator->max_index;
\r
11224 max_free_index = allocator->max_free_index;
\r
11225 current_free_index = allocator->current_free_index;
\r
11231 next = node->next;
\r
11232 index = node->index;
\r
11234 if (max_free_index != 0
\r
11235 && index + 1 > current_free_index) {
\r
11236 node->next = freelist;
\r
11239 else if (index < 20) {
\r
11243 if ((node->next = allocator->free[index]) == ((void*)0)
\r
11244 && index > max_index) {
\r
11245 max_index = index;
\r
11247 allocator->free[index] = node;
\r
11248 if (current_free_index >= index + 1)
\r
11249 current_free_index -= index + 1;
\r
11251 current_free_index = 0;
\r
11257 node->next = allocator->free[0];
\r
11258 allocator->free[0] = node;
\r
11259 if (current_free_index >= index + 1)
\r
11260 current_free_index -= index + 1;
\r
11262 current_free_index = 0;
\r
11264 } while ((node = next) != ((void*)0));
\r
11266 allocator->max_index = max_index;
\r
11267 allocator->current_free_index = current_free_index;
\r
11270 if (allocator->mutex)
\r
11271 apr_thread_mutex_unlock(allocator->mutex);
\r
11274 while (freelist != ((void*)0)) {
\r
11276 freelist = node->next;
\r
11285 apr_memnode_t * apr_allocator_alloc(apr_allocator_t *allocator,
\r
11288 return allocator_alloc(allocator, size);
\r
11291 void apr_allocator_free(apr_allocator_t *allocator,
\r
11292 apr_memnode_t *node)
\r
11294 allocator_free(allocator, node);
\r
11296 # 467 "./../memory/unix/apr_pools.c"
\r
11297 typedef struct cleanup_t cleanup_t;
\r
11300 struct process_chain {
\r
11302 apr_proc_t *proc;
\r
11303 apr_kill_conditions_e kill_how;
\r
11305 struct process_chain *next;
\r
11307 # 500 "./../memory/unix/apr_pools.c"
\r
11308 struct apr_pool_t {
\r
11309 apr_pool_t *parent;
\r
11310 apr_pool_t *child;
\r
11311 apr_pool_t *sibling;
\r
11312 apr_pool_t **ref;
\r
11313 cleanup_t *cleanups;
\r
11314 cleanup_t *free_cleanups;
\r
11315 apr_allocator_t *allocator;
\r
11316 struct process_chain *subprocesses;
\r
11317 apr_abortfunc_t abort_fn;
\r
11318 apr_hash_t *user_data;
\r
11322 apr_memnode_t *active;
\r
11323 apr_memnode_t *self;
\r
11324 char *self_first_avail;
\r
11325 # 535 "./../memory/unix/apr_pools.c"
\r
11326 cleanup_t *pre_cleanups;
\r
11328 # 545 "./../memory/unix/apr_pools.c"
\r
11329 static apr_byte_t apr_pools_initialized = 0;
\r
11330 static apr_pool_t *global_pool = ((void*)0);
\r
11333 static apr_allocator_t *global_allocator = ((void*)0);
\r
11334 # 560 "./../memory/unix/apr_pools.c"
\r
11335 static void run_cleanups(cleanup_t **c);
\r
11336 static void free_proc_chain(struct process_chain *procs);
\r
11337 # 572 "./../memory/unix/apr_pools.c"
\r
11338 apr_status_t apr_pool_initialize(void)
\r
11342 if (apr_pools_initialized++)
\r
11344 # 587 "./../memory/unix/apr_pools.c"
\r
11345 if ((rv = apr_allocator_create(&global_allocator)) != 0) {
\r
11346 apr_pools_initialized = 0;
\r
11350 if ((rv = apr_pool_create_ex(&global_pool, ((void*)0), ((void*)0),
\r
11351 global_allocator)) != 0) {
\r
11352 apr_allocator_destroy(global_allocator);
\r
11353 global_allocator = ((void*)0);
\r
11354 apr_pools_initialized = 0;
\r
11358 apr_pool_tag(global_pool, "apr_global_pool");
\r
11366 if ((rv = apr_atomic_init(global_pool)) != 0) {
\r
11372 apr_thread_mutex_t *mutex;
\r
11374 if ((rv = apr_thread_mutex_create(&mutex,
\r
11376 global_pool)) != 0) {
\r
11380 apr_allocator_mutex_set(global_allocator, mutex);
\r
11384 apr_allocator_owner_set(global_allocator, global_pool);
\r
11389 void apr_pool_terminate(void)
\r
11391 if (!apr_pools_initialized)
\r
11394 if (--apr_pools_initialized)
\r
11397 apr_pool_destroy(global_pool);
\r
11398 global_pool = ((void*)0);
\r
11400 global_allocator = ((void*)0);
\r
11402 # 668 "./../memory/unix/apr_pools.c"
\r
11403 void * apr_palloc(apr_pool_t *pool, apr_size_t in_size)
\r
11405 apr_memnode_t *active, *node;
\r
11407 apr_size_t size, free_index;
\r
11409 size = (((in_size) + ((8) - 1)) & ~((8) - 1));
\r
11410 if (size < in_size) {
\r
11411 if (pool->abort_fn)
\r
11412 pool->abort_fn(12);
\r
11414 return ((void*)0);
\r
11416 active = pool->active;
\r
11419 if (size <= ((apr_size_t)(active->endp - active->first_avail))) {
\r
11420 mem = active->first_avail;
\r
11421 active->first_avail += size;
\r
11426 node = active->next;
\r
11427 if (size <= ((apr_size_t)(node->endp - node->first_avail))) {
\r
11428 do { *node->ref = node->next; node->next->ref = node->ref; } while (0);
\r
11431 if ((node = allocator_alloc(pool->allocator, size)) == ((void*)0)) {
\r
11432 if (pool->abort_fn)
\r
11433 pool->abort_fn(12);
\r
11435 return ((void*)0);
\r
11439 node->free_index = 0;
\r
11441 mem = node->first_avail;
\r
11442 node->first_avail += size;
\r
11444 do { node->ref = active->ref; *node->ref = node; node->next = active; active->ref = &node->next; } while (0);
\r
11446 pool->active = node;
\r
11448 free_index = ((((active->endp - active->first_avail + 1) + (((1 << 12)) - 1)) & ~(((1 << 12)) - 1)) - (1 << 12)) >> 12;
\r
11451 active->free_index = (apr_uint32_t)free_index;
\r
11452 node = active->next;
\r
11453 if (free_index >= node->free_index)
\r
11457 node = node->next;
\r
11459 while (free_index < node->free_index);
\r
11461 do { *active->ref = active->next; active->next->ref = active->ref; } while (0);
\r
11462 do { active->ref = node->ref; *active->ref = active; active->next = node; node->ref = &active->next; } while (0);
\r
11466 # 740 "./../memory/unix/apr_pools.c"
\r
11467 void * apr_pcalloc(apr_pool_t *pool, apr_size_t size);
\r
11468 void * apr_pcalloc(apr_pool_t *pool, apr_size_t size)
\r
11472 if ((mem = apr_palloc(pool, size)) != ((void*)0)) {
\r
11473 memset(mem, 0, size);
\r
11484 void apr_pool_clear(apr_pool_t *pool)
\r
11486 apr_memnode_t *active;
\r
11489 run_cleanups(&pool->pre_cleanups);
\r
11490 pool->pre_cleanups = ((void*)0);
\r
11495 while (pool->child)
\r
11496 apr_pool_destroy(pool->child);
\r
11499 run_cleanups(&pool->cleanups);
\r
11500 pool->cleanups = ((void*)0);
\r
11501 pool->free_cleanups = ((void*)0);
\r
11504 free_proc_chain(pool->subprocesses);
\r
11505 pool->subprocesses = ((void*)0);
\r
11508 pool->user_data = ((void*)0);
\r
11513 active = pool->active = pool->self;
\r
11514 active->first_avail = pool->self_first_avail;
\r
11516 if (active->next == active)
\r
11519 *active->ref = ((void*)0);
\r
11520 allocator_free(pool->allocator, active->next);
\r
11521 active->next = active;
\r
11522 active->ref = &active->next;
\r
11525 void apr_pool_destroy(apr_pool_t *pool)
\r
11527 apr_memnode_t *active;
\r
11528 apr_allocator_t *allocator;
\r
11531 run_cleanups(&pool->pre_cleanups);
\r
11532 pool->pre_cleanups = ((void*)0);
\r
11537 while (pool->child)
\r
11538 apr_pool_destroy(pool->child);
\r
11541 run_cleanups(&pool->cleanups);
\r
11544 free_proc_chain(pool->subprocesses);
\r
11547 if (pool->parent) {
\r
11549 apr_thread_mutex_t *mutex;
\r
11551 if ((mutex = apr_allocator_mutex_get(pool->parent->allocator)) != ((void*)0))
\r
11552 apr_thread_mutex_lock(mutex);
\r
11555 if ((*pool->ref = pool->sibling) != ((void*)0))
\r
11556 pool->sibling->ref = pool->ref;
\r
11560 apr_thread_mutex_unlock(mutex);
\r
11567 allocator = pool->allocator;
\r
11568 active = pool->self;
\r
11569 *active->ref = ((void*)0);
\r
11572 if (apr_allocator_owner_get(allocator) == pool) {
\r
11576 apr_allocator_mutex_set(allocator, ((void*)0));
\r
11583 allocator_free(allocator, active);
\r
11590 if (apr_allocator_owner_get(allocator) == pool) {
\r
11591 apr_allocator_destroy(allocator);
\r
11595 apr_status_t apr_pool_create_ex(apr_pool_t **newpool,
\r
11596 apr_pool_t *parent,
\r
11597 apr_abortfunc_t abort_fn,
\r
11598 apr_allocator_t *allocator)
\r
11600 apr_pool_t *pool;
\r
11601 apr_memnode_t *node;
\r
11603 *newpool = ((void*)0);
\r
11606 parent = global_pool;
\r
11612 if (!abort_fn && parent)
\r
11613 abort_fn = parent->abort_fn;
\r
11615 if (allocator == ((void*)0))
\r
11616 allocator = parent->allocator;
\r
11618 if ((node = allocator_alloc(allocator,
\r
11619 (2 * (1 << 12)) - (((sizeof(apr_memnode_t)) + ((8) - 1)) & ~((8) - 1)))) == ((void*)0)) {
\r
11626 node->next = node;
\r
11627 node->ref = &node->next;
\r
11629 pool = (apr_pool_t *)node->first_avail;
\r
11630 node->first_avail = pool->self_first_avail = (char *)pool + (((sizeof(apr_pool_t)) + ((8) - 1)) & ~((8) - 1));
\r
11632 pool->allocator = allocator;
\r
11633 pool->active = pool->self = node;
\r
11634 pool->abort_fn = abort_fn;
\r
11635 pool->child = ((void*)0);
\r
11636 pool->cleanups = ((void*)0);
\r
11637 pool->free_cleanups = ((void*)0);
\r
11638 pool->pre_cleanups = ((void*)0);
\r
11639 pool->subprocesses = ((void*)0);
\r
11640 pool->user_data = ((void*)0);
\r
11641 pool->tag = ((void*)0);
\r
11647 if ((pool->parent = parent) != ((void*)0)) {
\r
11649 apr_thread_mutex_t *mutex;
\r
11651 if ((mutex = apr_allocator_mutex_get(parent->allocator)) != ((void*)0))
\r
11652 apr_thread_mutex_lock(mutex);
\r
11655 if ((pool->sibling = parent->child) != ((void*)0))
\r
11656 pool->sibling->ref = &pool->sibling;
\r
11658 parent->child = pool;
\r
11659 pool->ref = &parent->child;
\r
11663 apr_thread_mutex_unlock(mutex);
\r
11667 pool->sibling = ((void*)0);
\r
11668 pool->ref = ((void*)0);
\r
11678 apr_status_t apr_pool_create_core_ex(apr_pool_t **newpool,
\r
11679 apr_abortfunc_t abort_fn,
\r
11680 apr_allocator_t *allocator)
\r
11682 return apr_pool_create_unmanaged_ex(newpool, abort_fn, allocator);
\r
11685 apr_status_t apr_pool_create_unmanaged_ex(apr_pool_t **newpool,
\r
11686 apr_abortfunc_t abort_fn,
\r
11687 apr_allocator_t *allocator)
\r
11689 apr_pool_t *pool;
\r
11690 apr_memnode_t *node;
\r
11691 apr_allocator_t *pool_allocator;
\r
11693 *newpool = ((void*)0);
\r
11695 if (!apr_pools_initialized)
\r
11696 return (20000 + 2);
\r
11697 if ((pool_allocator = allocator) == ((void*)0)) {
\r
11698 if ((pool_allocator = malloc((((sizeof(apr_allocator_t)) + ((8) - 1)) & ~((8) - 1)))) == ((void*)0)) {
\r
11704 memset(pool_allocator, 0, (((sizeof(apr_allocator_t)) + ((8) - 1)) & ~((8) - 1)));
\r
11705 pool_allocator->max_free_index = 0;
\r
11707 if ((node = allocator_alloc(pool_allocator,
\r
11708 (2 * (1 << 12)) - (((sizeof(apr_memnode_t)) + ((8) - 1)) & ~((8) - 1)))) == ((void*)0)) {
\r
11715 node->next = node;
\r
11716 node->ref = &node->next;
\r
11718 pool = (apr_pool_t *)node->first_avail;
\r
11719 node->first_avail = pool->self_first_avail = (char *)pool + (((sizeof(apr_pool_t)) + ((8) - 1)) & ~((8) - 1));
\r
11721 pool->allocator = pool_allocator;
\r
11722 pool->active = pool->self = node;
\r
11723 pool->abort_fn = abort_fn;
\r
11724 pool->child = ((void*)0);
\r
11725 pool->cleanups = ((void*)0);
\r
11726 pool->free_cleanups = ((void*)0);
\r
11727 pool->pre_cleanups = ((void*)0);
\r
11728 pool->subprocesses = ((void*)0);
\r
11729 pool->user_data = ((void*)0);
\r
11730 pool->tag = ((void*)0);
\r
11731 pool->parent = ((void*)0);
\r
11732 pool->sibling = ((void*)0);
\r
11733 pool->ref = ((void*)0);
\r
11739 pool_allocator->owner = pool;
\r
11744 # 1036 "./../memory/unix/apr_pools.c"
\r
11745 struct psprintf_data {
\r
11746 apr_vformatter_buff_t vbuff;
\r
11747 apr_memnode_t *node;
\r
11748 apr_pool_t *pool;
\r
11749 apr_byte_t got_a_new_node;
\r
11750 apr_memnode_t *free;
\r
11755 static int psprintf_flush(apr_vformatter_buff_t *vbuff)
\r
11757 struct psprintf_data *ps = (struct psprintf_data *)vbuff;
\r
11758 apr_memnode_t *node, *active;
\r
11759 apr_size_t cur_len, size;
\r
11761 apr_pool_t *pool;
\r
11762 apr_size_t free_index;
\r
11765 active = ps->node;
\r
11766 strp = ps->vbuff.curpos;
\r
11767 cur_len = strp - active->first_avail;
\r
11768 size = cur_len << 1;
\r
11778 node = active->next;
\r
11779 if (!ps->got_a_new_node && size <= ((apr_size_t)(node->endp - node->first_avail))) {
\r
11781 do { *node->ref = node->next; node->next->ref = node->ref; } while (0);
\r
11782 do { node->ref = active->ref; *node->ref = node; node->next = active; active->ref = &node->next; } while (0);
\r
11784 node->free_index = 0;
\r
11786 pool->active = node;
\r
11788 free_index = ((((active->endp - active->first_avail + 1) + (((1 << 12)) - 1)) & ~(((1 << 12)) - 1)) - (1 << 12)) >> 12;
\r
11791 active->free_index = (apr_uint32_t)free_index;
\r
11792 node = active->next;
\r
11793 if (free_index < node->free_index) {
\r
11795 node = node->next;
\r
11797 while (free_index < node->free_index);
\r
11799 do { *active->ref = active->next; active->next->ref = active->ref; } while (0);
\r
11800 do { active->ref = node->ref; *active->ref = active; active->next = node; node->ref = &active->next; } while (0);
\r
11803 node = pool->active;
\r
11806 if ((node = allocator_alloc(pool->allocator, size)) == ((void*)0))
\r
11809 if (ps->got_a_new_node) {
\r
11810 active->next = ps->free;
\r
11811 ps->free = active;
\r
11814 ps->got_a_new_node = 1;
\r
11817 memcpy(node->first_avail, active->first_avail, cur_len);
\r
11820 ps->vbuff.curpos = node->first_avail + cur_len;
\r
11821 ps->vbuff.endpos = node->endp - 1;
\r
11826 char * apr_pvsprintf(apr_pool_t *pool, const char *fmt, va_list ap)
\r
11828 struct psprintf_data ps;
\r
11831 apr_memnode_t *active, *node;
\r
11832 apr_size_t free_index;
\r
11834 ps.node = active = pool->active;
\r
11836 ps.vbuff.curpos = ps.node->first_avail;
\r
11839 ps.vbuff.endpos = ps.node->endp - 1;
\r
11840 ps.got_a_new_node = 0;
\r
11841 ps.free = ((void*)0);
\r
11846 if (ps.node->first_avail == ps.node->endp) {
\r
11847 if (psprintf_flush(&ps.vbuff) == -1) {
\r
11848 if (pool->abort_fn) {
\r
11849 pool->abort_fn(12);
\r
11852 return ((void*)0);
\r
11856 if (apr_vformatter(psprintf_flush, &ps.vbuff, fmt, ap) == -1) {
\r
11857 if (pool->abort_fn)
\r
11858 pool->abort_fn(12);
\r
11860 return ((void*)0);
\r
11863 strp = ps.vbuff.curpos;
\r
11866 size = strp - ps.node->first_avail;
\r
11867 size = (((size) + ((8) - 1)) & ~((8) - 1));
\r
11868 strp = ps.node->first_avail;
\r
11869 ps.node->first_avail += size;
\r
11872 allocator_free(pool->allocator, ps.free);
\r
11877 if (!ps.got_a_new_node)
\r
11880 active = pool->active;
\r
11883 node->free_index = 0;
\r
11885 do { node->ref = active->ref; *node->ref = node; node->next = active; active->ref = &node->next; } while (0);
\r
11887 pool->active = node;
\r
11889 free_index = ((((active->endp - active->first_avail + 1) + (((1 << 12)) - 1)) & ~(((1 << 12)) - 1)) - (1 << 12)) >> 12;
\r
11892 active->free_index = (apr_uint32_t)free_index;
\r
11893 node = active->next;
\r
11895 if (free_index >= node->free_index)
\r
11899 node = node->next;
\r
11901 while (free_index < node->free_index);
\r
11903 do { *active->ref = active->next; active->next->ref = active->ref; } while (0);
\r
11904 do { active->ref = node->ref; *active->ref = active; active->next = node; node->ref = &active->next; } while (0);
\r
11908 # 2049 "./../memory/unix/apr_pools.c"
\r
11909 char * apr_psprintf(apr_pool_t *p, const char *fmt, ...)
\r
11914 __builtin_va_start(ap, fmt);
\r
11915 res = apr_pvsprintf(p, fmt, ap);
\r
11916 __builtin_va_end(ap);
\r
11924 void apr_pool_abort_set(apr_abortfunc_t abort_fn,
\r
11925 apr_pool_t *pool)
\r
11927 pool->abort_fn = abort_fn;
\r
11930 apr_abortfunc_t apr_pool_abort_get(apr_pool_t *pool)
\r
11932 return pool->abort_fn;
\r
11935 apr_pool_t * apr_pool_parent_get(apr_pool_t *pool)
\r
11944 return pool->parent;
\r
11947 apr_allocator_t * apr_pool_allocator_get(apr_pool_t *pool)
\r
11949 return pool->allocator;
\r
11955 int apr_pool_is_ancestor(apr_pool_t *a, apr_pool_t *b)
\r
11957 if (a == ((void*)0))
\r
11959 # 2108 "./../memory/unix/apr_pools.c"
\r
11970 void apr_pool_tag(apr_pool_t *pool, const char *tag)
\r
11980 apr_status_t apr_pool_userdata_set(const void *data, const char *key,
\r
11981 apr_status_t (*cleanup) (void *),
\r
11982 apr_pool_t *pool)
\r
11988 if (pool->user_data == ((void*)0))
\r
11989 pool->user_data = apr_hash_make(pool);
\r
11991 if (apr_hash_get(pool->user_data, key, (-1)) == ((void*)0)) {
\r
11992 char *new_key = apr_pstrdup(pool, key);
\r
11993 apr_hash_set(pool->user_data, new_key, (-1), data);
\r
11996 apr_hash_set(pool->user_data, key, (-1), data);
\r
12000 apr_pool_cleanup_register(pool, data, cleanup, cleanup);
\r
12005 apr_status_t apr_pool_userdata_setn(const void *data,
\r
12007 apr_status_t (*cleanup)(void *),
\r
12008 apr_pool_t *pool)
\r
12014 if (pool->user_data == ((void*)0))
\r
12015 pool->user_data = apr_hash_make(pool);
\r
12017 apr_hash_set(pool->user_data, key, (-1), data);
\r
12020 apr_pool_cleanup_register(pool, data, cleanup, cleanup);
\r
12025 apr_status_t apr_pool_userdata_get(void **data, const char *key,
\r
12026 apr_pool_t *pool)
\r
12032 if (pool->user_data == ((void*)0)) {
\r
12033 *data = ((void*)0);
\r
12036 *data = apr_hash_get(pool->user_data, key, (-1));
\r
12047 struct cleanup_t {
\r
12048 struct cleanup_t *next;
\r
12049 const void *data;
\r
12050 apr_status_t (*plain_cleanup_fn)(void *data);
\r
12051 apr_status_t (*child_cleanup_fn)(void *data);
\r
12054 void apr_pool_cleanup_register(apr_pool_t *p, const void *data,
\r
12055 apr_status_t (*plain_cleanup_fn)(void *data),
\r
12056 apr_status_t (*child_cleanup_fn)(void *data))
\r
12064 if (p != ((void*)0)) {
\r
12065 if (p->free_cleanups) {
\r
12067 c = p->free_cleanups;
\r
12068 p->free_cleanups = c->next;
\r
12070 c = apr_palloc(p, sizeof(cleanup_t));
\r
12073 c->plain_cleanup_fn = plain_cleanup_fn;
\r
12074 c->child_cleanup_fn = child_cleanup_fn;
\r
12075 c->next = p->cleanups;
\r
12080 void apr_pool_pre_cleanup_register(apr_pool_t *p, const void *data,
\r
12081 apr_status_t (*plain_cleanup_fn)(void *data))
\r
12089 if (p != ((void*)0)) {
\r
12090 if (p->free_cleanups) {
\r
12092 c = p->free_cleanups;
\r
12093 p->free_cleanups = c->next;
\r
12095 c = apr_palloc(p, sizeof(cleanup_t));
\r
12098 c->plain_cleanup_fn = plain_cleanup_fn;
\r
12099 c->next = p->pre_cleanups;
\r
12100 p->pre_cleanups = c;
\r
12104 void apr_pool_cleanup_kill(apr_pool_t *p, const void *data,
\r
12105 apr_status_t (*cleanup_fn)(void *))
\r
12107 cleanup_t *c, **lastp;
\r
12113 if (p == ((void*)0))
\r
12117 lastp = &p->cleanups;
\r
12119 # 2276 "./../memory/unix/apr_pools.c"
\r
12120 if (c->data == data && c->plain_cleanup_fn == cleanup_fn) {
\r
12121 *lastp = c->next;
\r
12123 c->next = p->free_cleanups;
\r
12124 p->free_cleanups = c;
\r
12128 lastp = &c->next;
\r
12133 c = p->pre_cleanups;
\r
12134 lastp = &p->pre_cleanups;
\r
12136 # 2301 "./../memory/unix/apr_pools.c"
\r
12137 if (c->data == data && c->plain_cleanup_fn == cleanup_fn) {
\r
12138 *lastp = c->next;
\r
12140 c->next = p->free_cleanups;
\r
12141 p->free_cleanups = c;
\r
12145 lastp = &c->next;
\r
12151 void apr_pool_child_cleanup_set(apr_pool_t *p, const void *data,
\r
12152 apr_status_t (*plain_cleanup_fn)(void *),
\r
12153 apr_status_t (*child_cleanup_fn)(void *))
\r
12161 if (p == ((void*)0))
\r
12166 if (c->data == data && c->plain_cleanup_fn == plain_cleanup_fn) {
\r
12167 c->child_cleanup_fn = child_cleanup_fn;
\r
12175 apr_status_t apr_pool_cleanup_run(apr_pool_t *p, void *data,
\r
12176 apr_status_t (*cleanup_fn)(void *))
\r
12178 apr_pool_cleanup_kill(p, data, cleanup_fn);
\r
12179 return (*cleanup_fn)(data);
\r
12182 static void run_cleanups(cleanup_t **cref)
\r
12184 cleanup_t *c = *cref;
\r
12188 (*c->plain_cleanup_fn)((void *)c->data);
\r
12195 static void run_child_cleanups(cleanup_t **cref)
\r
12197 cleanup_t *c = *cref;
\r
12201 (*c->child_cleanup_fn)((void *)c->data);
\r
12206 static void cleanup_pool_for_exec(apr_pool_t *p)
\r
12208 run_child_cleanups(&p->cleanups);
\r
12210 for (p = p->child; p; p = p->sibling)
\r
12211 cleanup_pool_for_exec(p);
\r
12214 void apr_pool_cleanup_for_exec(void)
\r
12216 cleanup_pool_for_exec(global_pool);
\r
12218 # 2402 "./../memory/unix/apr_pools.c"
\r
12219 apr_status_t apr_pool_cleanup_null(void *data)
\r
12224 # 2415 "./../memory/unix/apr_pools.c"
\r
12225 void apr_pool_note_subprocess(apr_pool_t *pool, apr_proc_t *proc,
\r
12226 apr_kill_conditions_e how)
\r
12228 struct process_chain *pc = apr_palloc(pool, sizeof(struct process_chain));
\r
12231 pc->kill_how = how;
\r
12232 pc->next = pool->subprocesses;
\r
12233 pool->subprocesses = pc;
\r
12236 static void free_proc_chain(struct process_chain *procs)
\r
12242 struct process_chain *pc;
\r
12243 int need_timeout = 0;
\r
12244 apr_time_t timeout_interval;
\r
12248 # 2448 "./../memory/unix/apr_pools.c"
\r
12249 for (pc = procs; pc; pc = pc->next) {
\r
12250 if (apr_proc_wait(pc->proc, ((void*)0), ((void*)0), APR_NOWAIT) != ((20000 + 50000) + 6))
\r
12251 pc->kill_how = APR_KILL_NEVER;
\r
12255 for (pc = procs; pc; pc = pc->next) {
\r
12257 if ((pc->kill_how == APR_KILL_AFTER_TIMEOUT)
\r
12258 || (pc->kill_how == APR_KILL_ONLY_ONCE)) {
\r
12265 if (apr_proc_kill(pc->proc, 15) == 0)
\r
12266 need_timeout = 1;
\r
12268 else if (pc->kill_how == APR_KILL_ALWAYS) {
\r
12274 apr_proc_kill(pc->proc, 9);
\r
12282 if (need_timeout) {
\r
12283 timeout_interval = 46875;
\r
12284 apr_sleep(timeout_interval);
\r
12288 need_timeout = 0;
\r
12289 for (pc = procs; pc; pc = pc->next) {
\r
12290 if (pc->kill_how == APR_KILL_AFTER_TIMEOUT) {
\r
12291 if (apr_proc_wait(pc->proc, ((void*)0), ((void*)0), APR_NOWAIT)
\r
12292 == ((20000 + 50000) + 6))
\r
12293 need_timeout = 1;
\r
12295 pc->kill_how = APR_KILL_NEVER;
\r
12298 if (need_timeout) {
\r
12299 if (timeout_interval >= 3000000) {
\r
12302 apr_sleep(timeout_interval);
\r
12303 timeout_interval *= 2;
\r
12305 } while (need_timeout);
\r
12312 for (pc = procs; pc; pc = pc->next) {
\r
12313 if (pc->kill_how == APR_KILL_AFTER_TIMEOUT)
\r
12314 apr_proc_kill(pc->proc, 9);
\r
12318 for (pc = procs; pc; pc = pc->next) {
\r
12319 if (pc->kill_how != APR_KILL_NEVER)
\r
12320 (void)apr_proc_wait(pc->proc, ((void*)0), ((void*)0), APR_WAIT);
\r
12323 # 2530 "./../memory/unix/apr_pools.c"
\r
12324 void * apr_palloc_debug(apr_pool_t *pool, apr_size_t size,
\r
12325 const char *file_line)
\r
12327 return apr_palloc(pool, size);
\r
12330 void * apr_pcalloc_debug(apr_pool_t *pool, apr_size_t size,
\r
12331 const char *file_line)
\r
12333 return apr_pcalloc(pool, size);
\r
12336 void apr_pool_clear_debug(apr_pool_t *pool,
\r
12337 const char *file_line)
\r
12339 apr_pool_clear(pool);
\r
12342 void apr_pool_destroy_debug(apr_pool_t *pool,
\r
12343 const char *file_line)
\r
12345 apr_pool_destroy(pool);
\r
12348 apr_status_t apr_pool_create_ex_debug(apr_pool_t **newpool,
\r
12349 apr_pool_t *parent,
\r
12350 apr_abortfunc_t abort_fn,
\r
12351 apr_allocator_t *allocator,
\r
12352 const char *file_line)
\r
12354 return apr_pool_create_ex(newpool, parent, abort_fn, allocator);
\r
12357 apr_status_t apr_pool_create_core_ex_debug(apr_pool_t **newpool,
\r
12358 apr_abortfunc_t abort_fn,
\r
12359 apr_allocator_t *allocator,
\r
12360 const char *file_line)
\r
12362 return apr_pool_create_unmanaged_ex(newpool, abort_fn, allocator);
\r
12365 apr_status_t apr_pool_create_unmanaged_ex_debug(apr_pool_t **newpool,
\r
12366 apr_abortfunc_t abort_fn,
\r
12367 apr_allocator_t *allocator,
\r
12368 const char *file_line)
\r
12370 return apr_pool_create_unmanaged_ex(newpool, abort_fn, allocator);
\r
12373 # 1 "./../misc/unix/start.c" 1
\r
12374 # 20 "./../misc/unix/start.c"
\r
12375 # 1 "../include/apr_signal.h" 1
\r
12376 # 57 "../include/apr_signal.h"
\r
12377 typedef void apr_sigfunc_t(int);
\r
12384 apr_sigfunc_t * apr_signal(int signo, apr_sigfunc_t * func);
\r
12385 # 80 "../include/apr_signal.h"
\r
12386 const char * apr_signal_description_get(int signum);
\r
12393 void apr_signal_init(apr_pool_t *pglobal);
\r
12400 apr_status_t apr_signal_block(int signum);
\r
12407 apr_status_t apr_signal_unblock(int signum);
\r
12408 # 21 "./../misc/unix/start.c" 2
\r
12412 # 1 "../include/arch/unix/apr_arch_internal_time.h" 1
\r
12413 # 22 "../include/arch/unix/apr_arch_internal_time.h"
\r
12414 void apr_unix_setup_time(void);
\r
12415 # 25 "./../misc/unix/start.c" 2
\r
12418 apr_status_t apr_app_initialize(int *argc,
\r
12419 const char * const * *argv,
\r
12420 const char * const * *env)
\r
12427 return apr_initialize();
\r
12430 static int initialized = 0;
\r
12432 apr_status_t apr_initialize(void)
\r
12434 apr_pool_t *pool;
\r
12435 apr_status_t status;
\r
12437 if (initialized++) {
\r
12442 apr_proc_mutex_unix_setup_lock();
\r
12443 apr_unix_setup_time();
\r
12446 if ((status = apr_pool_initialize()) != 0)
\r
12449 if (apr_pool_create_ex(&pool, ((void*)0), ((void*)0), ((void*)0)) != 0) {
\r
12450 return (20000 + 2);
\r
12453 apr_pool_tag(pool, "apr_initialize");
\r
12454 # 71 "./../misc/unix/start.c"
\r
12455 apr_signal_init(pool);
\r
12460 void apr_terminate(void)
\r
12463 if (initialized) {
\r
12466 apr_pool_terminate();
\r
12470 void apr_terminate2(void)
\r
12475 # 1 "./../time/unix/time.c" 1
\r
12476 # 43 "./../time/unix/time.c"
\r
12477 static apr_int32_t get_offset(struct tm *tm)
\r
12480 return tm->tm_gmtoff;
\r
12481 # 64 "./../time/unix/time.c"
\r
12484 apr_status_t apr_time_ansi_put(apr_time_t *result,
\r
12487 *result = (apr_time_t)input * 1000000L;
\r
12492 apr_time_t apr_time_now(void)
\r
12494 struct timeval tv;
\r
12495 gettimeofday(&tv, ((void*)0));
\r
12496 return tv.tv_sec * 1000000L + tv.tv_usec;
\r
12499 static void explode_time(apr_time_exp_t *xt, apr_time_t t,
\r
12500 apr_int32_t offset, int use_localtime)
\r
12503 time_t tt = (t / 1000000L) + offset;
\r
12504 xt->tm_usec = t % 1000000L;
\r
12507 if (use_localtime)
\r
12508 localtime_r(&tt, &tm);
\r
12510 gmtime_r(&tt, &tm);
\r
12518 xt->tm_sec = tm.tm_sec;
\r
12519 xt->tm_min = tm.tm_min;
\r
12520 xt->tm_hour = tm.tm_hour;
\r
12521 xt->tm_mday = tm.tm_mday;
\r
12522 xt->tm_mon = tm.tm_mon;
\r
12523 xt->tm_year = tm.tm_year;
\r
12524 xt->tm_wday = tm.tm_wday;
\r
12525 xt->tm_yday = tm.tm_yday;
\r
12526 xt->tm_isdst = tm.tm_isdst;
\r
12527 xt->tm_gmtoff = get_offset(&tm);
\r
12530 apr_status_t apr_time_exp_tz(apr_time_exp_t *result,
\r
12531 apr_time_t input, apr_int32_t offs)
\r
12533 explode_time(result, input, offs, 0);
\r
12534 result->tm_gmtoff = offs;
\r
12538 apr_status_t apr_time_exp_gmt(apr_time_exp_t *result,
\r
12539 apr_time_t input)
\r
12541 return apr_time_exp_tz(result, input, 0);
\r
12544 apr_status_t apr_time_exp_lt(apr_time_exp_t *result,
\r
12545 apr_time_t input)
\r
12551 explode_time(result, input, 0, 1);
\r
12556 apr_status_t apr_time_exp_get(apr_time_t *t, apr_time_exp_t *xt)
\r
12558 apr_time_t year = xt->tm_year;
\r
12560 static const int dayoffset[12] =
\r
12561 {306, 337, 0, 31, 61, 92, 122, 153, 184, 214, 245, 275};
\r
12565 if (xt->tm_mon < 2)
\r
12570 days = year * 365 + year / 4 - year / 100 + (year / 100 + 3) / 4;
\r
12571 days += dayoffset[xt->tm_mon] + xt->tm_mday - 1;
\r
12573 days = ((days * 24 + xt->tm_hour) * 60 + xt->tm_min) * 60 + xt->tm_sec;
\r
12576 return (20000 + 4);
\r
12578 *t = days * 1000000L + xt->tm_usec;
\r
12582 apr_status_t apr_time_exp_gmt_get(apr_time_t *t,
\r
12583 apr_time_exp_t *xt)
\r
12585 apr_status_t status = apr_time_exp_get(t, xt);
\r
12587 *t -= (apr_time_t) xt->tm_gmtoff * 1000000L;
\r
12591 apr_status_t apr_os_imp_time_get(apr_os_imp_time_t **ostime,
\r
12592 apr_time_t *aprtime)
\r
12594 (*ostime)->tv_usec = *aprtime % 1000000L;
\r
12595 (*ostime)->tv_sec = *aprtime / 1000000L;
\r
12599 apr_status_t apr_os_exp_time_get(apr_os_exp_time_t **ostime,
\r
12600 apr_time_exp_t *aprtime)
\r
12602 (*ostime)->tm_sec = aprtime->tm_sec;
\r
12603 (*ostime)->tm_min = aprtime->tm_min;
\r
12604 (*ostime)->tm_hour = aprtime->tm_hour;
\r
12605 (*ostime)->tm_mday = aprtime->tm_mday;
\r
12606 (*ostime)->tm_mon = aprtime->tm_mon;
\r
12607 (*ostime)->tm_year = aprtime->tm_year;
\r
12608 (*ostime)->tm_wday = aprtime->tm_wday;
\r
12609 (*ostime)->tm_yday = aprtime->tm_yday;
\r
12610 (*ostime)->tm_isdst = aprtime->tm_isdst;
\r
12613 (*ostime)->tm_gmtoff = aprtime->tm_gmtoff;
\r
12621 apr_status_t apr_os_imp_time_put(apr_time_t *aprtime,
\r
12622 apr_os_imp_time_t **ostime,
\r
12623 apr_pool_t *cont)
\r
12625 *aprtime = (*ostime)->tv_sec * 1000000L + (*ostime)->tv_usec;
\r
12629 apr_status_t apr_os_exp_time_put(apr_time_exp_t *aprtime,
\r
12630 apr_os_exp_time_t **ostime,
\r
12631 apr_pool_t *cont)
\r
12633 aprtime->tm_sec = (*ostime)->tm_sec;
\r
12634 aprtime->tm_min = (*ostime)->tm_min;
\r
12635 aprtime->tm_hour = (*ostime)->tm_hour;
\r
12636 aprtime->tm_mday = (*ostime)->tm_mday;
\r
12637 aprtime->tm_mon = (*ostime)->tm_mon;
\r
12638 aprtime->tm_year = (*ostime)->tm_year;
\r
12639 aprtime->tm_wday = (*ostime)->tm_wday;
\r
12640 aprtime->tm_yday = (*ostime)->tm_yday;
\r
12641 aprtime->tm_isdst = (*ostime)->tm_isdst;
\r
12644 aprtime->tm_gmtoff = (*ostime)->tm_gmtoff;
\r
12652 void apr_sleep(apr_interval_time_t t)
\r
12661 struct timeval tv;
\r
12662 tv.tv_usec = t % 1000000L;
\r
12663 tv.tv_sec = t / 1000000L;
\r
12664 select(0, ((void*)0), ((void*)0), ((void*)0), &tv);
\r
12667 # 296 "./../time/unix/time.c"
\r
12668 void apr_unix_setup_time(void)
\r
12670 # 339 "./../time/unix/time.c"
\r
12676 void apr_time_clock_hires(apr_pool_t *p)
\r
12681 # 1 "./../atomic/unix/builtins.c" 1
\r
12682 # 17 "./../atomic/unix/builtins.c"
\r
12683 # 1 "../include/arch/unix/apr_arch_atomic.h" 1
\r
12684 # 18 "./../atomic/unix/builtins.c" 2
\r
12688 apr_status_t apr_atomic_init(apr_pool_t *p)
\r
12693 apr_uint32_t apr_atomic_read32(volatile apr_uint32_t *mem)
\r
12698 void apr_atomic_set32(volatile apr_uint32_t *mem, apr_uint32_t val)
\r
12703 apr_uint32_t apr_atomic_add32(volatile apr_uint32_t *mem, apr_uint32_t val)
\r
12705 return __sync_fetch_and_add(mem, val);
\r
12708 void apr_atomic_sub32(volatile apr_uint32_t *mem, apr_uint32_t val)
\r
12710 __sync_fetch_and_sub(mem, val);
\r
12713 apr_uint32_t apr_atomic_inc32(volatile apr_uint32_t *mem)
\r
12715 return __sync_fetch_and_add(mem, 1);
\r
12718 int apr_atomic_dec32(volatile apr_uint32_t *mem)
\r
12720 return __sync_sub_and_fetch(mem, 1);
\r
12723 apr_uint32_t apr_atomic_cas32(volatile apr_uint32_t *mem, apr_uint32_t with,
\r
12724 apr_uint32_t cmp)
\r
12726 return __sync_val_compare_and_swap(mem, cmp, with);
\r
12729 apr_uint32_t apr_atomic_xchg32(volatile apr_uint32_t *mem, apr_uint32_t val)
\r
12731 __sync_synchronize();
\r
12733 return __sync_lock_test_and_set(mem, val);
\r
12736 void* apr_atomic_casptr(volatile void **mem, void *with, const void *cmp)
\r
12738 return (void*) __sync_val_compare_and_swap(mem, cmp, with);
\r
12741 void* apr_atomic_xchgptr(volatile void **mem, void *with)
\r
12743 __sync_synchronize();
\r
12745 return (void*) __sync_lock_test_and_set(mem, with);
\r
12748 # 1 "./../threadproc/unix/signals.c" 1
\r
12749 # 18 "./../threadproc/unix/signals.c"
\r
12750 # 1 "../include/arch/unix/apr_arch_threadproc.h" 1
\r
12751 # 55 "../include/arch/unix/apr_arch_threadproc.h"
\r
12752 struct apr_thread_t {
\r
12753 apr_pool_t *pool;
\r
12756 apr_thread_start_t func;
\r
12757 apr_status_t exitval;
\r
12760 struct apr_threadattr_t {
\r
12761 apr_pool_t *pool;
\r
12762 pthread_attr_t attr;
\r
12765 struct apr_threadkey_t {
\r
12766 apr_pool_t *pool;
\r
12767 pthread_key_t key;
\r
12770 struct apr_thread_once_t {
\r
12771 pthread_once_t once;
\r
12776 struct apr_procattr_t {
\r
12777 apr_pool_t *pool;
\r
12778 apr_file_t *parent_in;
\r
12779 apr_file_t *child_in;
\r
12780 apr_file_t *parent_out;
\r
12781 apr_file_t *child_out;
\r
12782 apr_file_t *parent_err;
\r
12783 apr_file_t *child_err;
\r
12785 apr_int32_t cmdtype;
\r
12786 apr_int32_t detached;
\r
12788 struct rlimit *limit_cpu;
\r
12791 struct rlimit *limit_mem;
\r
12794 struct rlimit *limit_nproc;
\r
12797 struct rlimit *limit_nofile;
\r
12799 apr_child_errfn_t *errfn;
\r
12800 apr_int32_t errchk;
\r
12804 # 19 "./../threadproc/unix/signals.c" 2
\r
12810 # 1 "/usr/include/assert.h" 1 3 4
\r
12811 # 69 "/usr/include/assert.h" 3 4
\r
12812 extern void __assert_fail (const char *__assertion, const char *__file,
\r
12813 unsigned int __line, const char *__function)
\r
12814 __attribute__ ((__nothrow__ )) __attribute__ ((__noreturn__));
\r
12817 extern void __assert_perror_fail (int __errnum, const char *__file,
\r
12818 unsigned int __line, const char *__function)
\r
12819 __attribute__ ((__nothrow__ )) __attribute__ ((__noreturn__));
\r
12824 extern void __assert (const char *__assertion, const char *__file, int __line)
\r
12825 __attribute__ ((__nothrow__ )) __attribute__ ((__noreturn__));
\r
12826 # 25 "./../threadproc/unix/signals.c" 2
\r
12827 # 35 "./../threadproc/unix/signals.c"
\r
12828 apr_status_t apr_proc_kill(apr_proc_t *proc, int signum)
\r
12830 # 48 "./../threadproc/unix/signals.c"
\r
12831 if (kill(proc->pid, signum) == -1) {
\r
12832 return (*__errno_location ());
\r
12837 # 74 "./../threadproc/unix/signals.c"
\r
12838 apr_sigfunc_t * apr_signal(int signo, apr_sigfunc_t * func)
\r
12840 struct sigaction act, oact;
\r
12842 act.__sigaction_handler.sa_handler = func;
\r
12843 sigemptyset(&act.sa_mask);
\r
12844 act.sa_flags = 0;
\r
12846 act.sa_flags |= 0x20000000;
\r
12847 # 103 "./../threadproc/unix/signals.c"
\r
12848 if (sigaction(signo, &act, &oact) < 0)
\r
12849 return ((__sighandler_t) -1);
\r
12850 return oact.__sigaction_handler.sa_handler;
\r
12859 void apr_signal_init(apr_pool_t *pglobal)
\r
12862 const char *apr_signal_description_get(int signum)
\r
12864 return (signum >= 0) ? sys_siglist[signum] : "unknown signal (number)";
\r
12866 # 274 "./../threadproc/unix/signals.c"
\r
12867 static void remove_sync_sigs(sigset_t *sig_mask)
\r
12870 sigdelset(sig_mask, 6);
\r
12873 sigdelset(sig_mask, 7);
\r
12879 sigdelset(sig_mask, 8);
\r
12882 sigdelset(sig_mask, 4);
\r
12885 sigdelset(sig_mask, 6);
\r
12888 sigdelset(sig_mask, 13);
\r
12891 sigdelset(sig_mask, 11);
\r
12894 sigdelset(sig_mask, 31);
\r
12897 sigdelset(sig_mask, 5);
\r
12898 # 315 "./../threadproc/unix/signals.c"
\r
12899 sigdelset(sig_mask, 12);
\r
12903 apr_status_t apr_signal_thread(int(*signal_handler)(int signum))
\r
12905 sigset_t sig_mask;
\r
12907 int (*sig_func)(int signum) = (int (*)(int))signal_handler;
\r
12911 sigfillset(&sig_mask);
\r
12918 sigdelset(&sig_mask, 9);
\r
12921 sigdelset(&sig_mask, 19);
\r
12924 sigdelset(&sig_mask, 18);
\r
12931 remove_sync_sigs(&sig_mask);
\r
12932 # 379 "./../threadproc/unix/signals.c"
\r
12935 int signal_received;
\r
12937 if (sigwait((&sig_mask),(&signal_received)) != 0)
\r
12942 if (sig_func(signal_received) == 1) {
\r
12953 apr_status_t apr_setup_signal_thread(void)
\r
12955 sigset_t sig_mask;
\r
12957 # 416 "./../threadproc/unix/signals.c"
\r
12958 sigfillset(&sig_mask);
\r
12959 remove_sync_sigs(&sig_mask);
\r
12966 if ((rv = pthread_sigmask(2, &sig_mask, ((void*)0))) != 0) {
\r
12977 apr_status_t apr_signal_block(int signum)
\r
12980 sigset_t sig_mask;
\r
12983 sigemptyset(&sig_mask);
\r
12985 sigaddset(&sig_mask, signum);
\r
12992 if ((rv = pthread_sigmask(0, &sig_mask, ((void*)0))) != 0) {
\r
13004 apr_status_t apr_signal_unblock(int signum)
\r
13007 sigset_t sig_mask;
\r
13010 sigemptyset(&sig_mask);
\r
13012 sigaddset(&sig_mask, signum);
\r
13019 if ((rv = pthread_sigmask(1, &sig_mask, ((void*)0))) != 0) {
\r
13031 # 1 "./../threadproc/unix/thread.c" 1
\r
13032 # 19 "./../threadproc/unix/thread.c"
\r
13033 # 1 "../include/arch/unix/apr_arch_threadproc.h" 1
\r
13034 # 20 "./../threadproc/unix/thread.c" 2
\r
13041 static apr_status_t threadattr_cleanup(void *data)
\r
13043 apr_threadattr_t *attr = data;
\r
13046 rv = pthread_attr_destroy(&attr->attr);
\r
13055 apr_status_t apr_threadattr_create(apr_threadattr_t **new,
\r
13056 apr_pool_t *pool)
\r
13058 apr_status_t stat;
\r
13060 (*new) = apr_palloc(pool, sizeof(apr_threadattr_t));
\r
13061 (*new)->pool = pool;
\r
13062 stat = pthread_attr_init(&(*new)->attr);
\r
13065 apr_pool_cleanup_register(pool, *new, threadattr_cleanup,
\r
13066 apr_pool_cleanup_null);
\r
13082 apr_status_t apr_threadattr_detach_set(apr_threadattr_t *attr,
\r
13085 apr_status_t stat;
\r
13091 if ((stat = pthread_attr_setdetachstate(&attr->attr,
\r
13092 ((on) ? PTHREAD_CREATE_DETACHED : PTHREAD_CREATE_JOINABLE))) == 0) {
\r
13105 apr_status_t apr_threadattr_detach_get(apr_threadattr_t *attr)
\r
13112 pthread_attr_getdetachstate(&attr->attr, &state);
\r
13114 if (state == ((1) ? PTHREAD_CREATE_DETACHED : PTHREAD_CREATE_JOINABLE))
\r
13115 return ((20000 + 50000) + 3);
\r
13116 return ((20000 + 50000) + 4);
\r
13119 apr_status_t apr_threadattr_stacksize_set(apr_threadattr_t *attr,
\r
13120 apr_size_t stacksize)
\r
13124 stat = pthread_attr_setstacksize(&attr->attr, stacksize);
\r
13135 apr_status_t apr_threadattr_guardsize_set(apr_threadattr_t *attr,
\r
13141 rv = pthread_attr_setguardsize(&attr->attr, size);
\r
13154 static void *dummy_worker(void *opaque)
\r
13156 apr_thread_t *thread = (apr_thread_t*)opaque;
\r
13157 return thread->func(thread, thread->data);
\r
13160 apr_status_t apr_thread_create(apr_thread_t **new,
\r
13161 apr_threadattr_t *attr,
\r
13162 apr_thread_start_t func,
\r
13164 apr_pool_t *pool)
\r
13166 apr_status_t stat;
\r
13167 pthread_attr_t *temp;
\r
13169 (*new) = (apr_thread_t *)apr_pcalloc(pool, sizeof(apr_thread_t));
\r
13171 if ((*new) == ((void*)0)) {
\r
13175 (*new)->td = (pthread_t *)apr_pcalloc(pool, sizeof(pthread_t));
\r
13177 if ((*new)->td == ((void*)0)) {
\r
13181 (*new)->data = data;
\r
13182 (*new)->func = func;
\r
13185 temp = &attr->attr;
\r
13187 temp = ((void*)0);
\r
13189 stat = apr_pool_create_ex(&(*new)->pool, pool, ((void*)0), ((void*)0));
\r
13194 if ((stat = pthread_create((*new)->td, temp, dummy_worker, (*new))) == 0) {
\r
13206 apr_os_thread_t apr_os_thread_current(void)
\r
13208 return pthread_self();
\r
13211 int apr_os_thread_equal(apr_os_thread_t tid1,
\r
13212 apr_os_thread_t tid2)
\r
13214 return pthread_equal(tid1, tid2);
\r
13217 apr_status_t apr_thread_exit(apr_thread_t *thd,
\r
13218 apr_status_t retval)
\r
13220 thd->exitval = retval;
\r
13221 apr_pool_destroy(thd->pool);
\r
13222 pthread_exit(((void*)0));
\r
13226 apr_status_t apr_thread_join(apr_status_t *retval,
\r
13227 apr_thread_t *thd)
\r
13229 apr_status_t stat;
\r
13230 apr_status_t *thread_stat;
\r
13232 if ((stat = pthread_join(*thd->td,(void *)&thread_stat)) == 0) {
\r
13233 *retval = thd->exitval;
\r
13245 apr_status_t apr_thread_detach(apr_thread_t *thd)
\r
13247 apr_status_t stat;
\r
13252 if ((stat = pthread_detach(*thd->td)) == 0) {
\r
13266 void apr_thread_yield(void)
\r
13281 apr_status_t apr_thread_data_get(void **data, const char *key,
\r
13282 apr_thread_t *thread)
\r
13284 return apr_pool_userdata_get(data, key, thread->pool);
\r
13287 apr_status_t apr_thread_data_set(void *data, const char *key,
\r
13288 apr_status_t (*cleanup)(void *),
\r
13289 apr_thread_t *thread)
\r
13291 return apr_pool_userdata_set(data, key, cleanup, thread->pool);
\r
13294 apr_status_t apr_os_thread_get(apr_os_thread_t **thethd,
\r
13295 apr_thread_t *thd)
\r
13297 *thethd = thd->td;
\r
13301 apr_status_t apr_os_thread_put(apr_thread_t **thd,
\r
13302 apr_os_thread_t *thethd,
\r
13303 apr_pool_t *pool)
\r
13305 if (pool == ((void*)0)) {
\r
13306 return (20000 + 2);
\r
13309 if ((*thd) == ((void*)0)) {
\r
13310 (*thd) = (apr_thread_t *)apr_pcalloc(pool, sizeof(apr_thread_t));
\r
13311 (*thd)->pool = pool;
\r
13314 (*thd)->td = thethd;
\r
13318 apr_status_t apr_thread_once_init(apr_thread_once_t **control,
\r
13321 static const pthread_once_t once_init = 0;
\r
13323 *control = apr_palloc(p, sizeof(**control));
\r
13324 (*control)->once = once_init;
\r
13328 apr_status_t apr_thread_once(apr_thread_once_t *control,
\r
13329 void (*func)(void))
\r
13331 return pthread_once(&control->once, func);
\r
13334 apr_pool_t * apr_thread_pool_get (const apr_thread_t *thethread) { return thethread->pool; }
\r
13336 # 1 "./../test/abts.c" 1
\r
13337 # 17 "./../test/abts.c"
\r
13338 # 1 "./../test/abts.h" 1
\r
13339 # 18 "./../test/abts.c" 2
\r
13340 # 1 "./../test/abts_tests.h" 1
\r
13341 # 20 "./../test/abts_tests.h"
\r
13342 # 1 "./../test/abts.h" 1
\r
13343 # 21 "./../test/abts_tests.h" 2
\r
13344 # 1 "./../test/testutil.h" 1
\r
13345 # 19 "./../test/testutil.h"
\r
13346 # 1 "./../test/abts.h" 1
\r
13347 # 20 "./../test/testutil.h" 2
\r
13348 # 22 "./../test/abts_tests.h" 2
\r
13350 const struct testlist {
\r
13351 abts_suite *(*func)(abts_suite *suite);
\r
13399 # 19 "./../test/abts.c" 2
\r
13400 # 1 "./../test/testutil.h" 1
\r
13401 # 19 "./../test/testutil.h"
\r
13402 # 1 "./../test/abts.h" 1
\r
13403 # 20 "./../test/testutil.h" 2
\r
13404 # 20 "./../test/abts.c" 2
\r
13407 static char status[6] = {'|', '/', '-', '|', '\\', '-'};
\r
13408 static int curr_char;
\r
13409 static int verbose = 0;
\r
13410 static int exclude = 0;
\r
13411 static int quiet = 0;
\r
13412 static int list_tests = 0;
\r
13414 const char **testlist = ((void*)0);
\r
13416 static int find_test_name(const char *testname) {
\r
13418 for (i = 0; testlist[i] != ((void*)0); i++) {
\r
13419 if (!strcmp(testlist[i], testname)) {
\r
13427 static int should_test_run(const char *testname) {
\r
13429 if (list_tests == 1) {
\r
13432 if (testlist == ((void*)0)) {
\r
13435 found = find_test_name(testname);
\r
13436 if ((found && !exclude) || (!found && exclude)) {
\r
13442 static void reset_status(void)
\r
13447 static void update_status(void)
\r
13450 curr_char = (curr_char + 1) % 6;
\r
13451 fprintf(stdout, "\b%c", status[curr_char]);
\r
13456 static void end_suite(abts_suite *suite)
\r
13458 if (suite != ((void*)0)) {
\r
13459 sub_suite *last = suite->tail;
\r
13461 fprintf(stdout, "\b");
\r
13464 if (last->failed == 0) {
\r
13465 fprintf(stdout, "SUCCESS\n");
\r
13469 fprintf(stdout, "FAILED %d of %d\n", last->failed, last->num_test);
\r
13475 abts_suite *abts_add_suite(abts_suite *suite, const char *suite_name_full)
\r
13477 sub_suite *subsuite;
\r
13479 const char *suite_name;
\r
13483 if (suite && suite->tail &&!suite->tail->not_run) {
\r
13484 end_suite(suite);
\r
13487 subsuite = malloc(sizeof(*subsuite));
\r
13488 subsuite->num_test = 0;
\r
13489 subsuite->failed = 0;
\r
13490 subsuite->next = ((void*)0);
\r
13493 suite_name = strrchr(suite_name_full, '/');
\r
13494 if (!suite_name) {
\r
13495 suite_name = strrchr(suite_name_full, '\\');
\r
13497 if (suite_name) {
\r
13500 suite_name = suite_name_full;
\r
13502 p = strrchr(suite_name, '.');
\r
13504 subsuite->name = memcpy(calloc(p - suite_name + 1, 1),
\r
13505 suite_name, p - suite_name);
\r
13508 subsuite->name = suite_name;
\r
13511 if (list_tests) {
\r
13512 fprintf(stdout, "%s\n", subsuite->name);
\r
13515 subsuite->not_run = 0;
\r
13517 if (suite == ((void*)0)) {
\r
13518 suite = malloc(sizeof(*suite));
\r
13519 suite->head = subsuite;
\r
13520 suite->tail = subsuite;
\r
13523 suite->tail->next = subsuite;
\r
13524 suite->tail = subsuite;
\r
13527 if (!should_test_run(subsuite->name)) {
\r
13528 subsuite->not_run = 1;
\r
13533 fprintf(stdout, "%-20s: ", subsuite->name);
\r
13540 void abts_run_test(abts_suite *ts, test_func f, void *value)
\r
13545 if (!should_test_run(ts->tail->name)) {
\r
13563 static int report(abts_suite *suite)
\r
13568 if (suite && suite->tail &&!suite->tail->not_run) {
\r
13569 end_suite(suite);
\r
13572 for (dptr = suite->head; dptr; dptr = dptr->next) {
\r
13573 count += dptr->failed;
\r
13576 if (list_tests) {
\r
13580 if (count == 0) {
\r
13581 printf("All tests passed.\n");
\r
13585 dptr = suite->head;
\r
13586 fprintf(stdout, "%-15s\t\tTotal\tFail\tFailed %%\n", "Failed Tests");
\r
13587 fprintf(stdout, "===================================================\n");
\r
13588 while (dptr != ((void*)0)) {
\r
13589 if (dptr->failed != 0) {
\r
13590 float percent = ((float)dptr->failed / (float)dptr->num_test);
\r
13591 fprintf(stdout, "%-15s\t\t%5d\t%4d\t%6.2f%%\n", dptr->name,
\r
13592 dptr->num_test, dptr->failed, percent * 100);
\r
13594 dptr = dptr->next;
\r
13599 void abts_log_message(const char *fmt, ...)
\r
13605 __builtin_va_start(args, fmt);
\r
13606 vfprintf(stderr, fmt, args);
\r
13607 __builtin_va_end(args);
\r
13608 fprintf(stderr, "\n");
\r
13613 void abts_int_equal(abts_case *tc, const int expected, const int actual, int lineno)
\r
13616 if (tc->failed) return;
\r
13618 if (expected == actual) return;
\r
13622 fprintf(stderr, "Line %d: expected <%d>, but saw <%d>\n", lineno, expected, actual);
\r
13627 void abts_int_nequal(abts_case *tc, const int expected, const int actual, int lineno)
\r
13630 if (tc->failed) return;
\r
13632 if (expected != actual) return;
\r
13636 fprintf(stderr, "Line %d: expected something other than <%d>, but saw <%d>\n",
\r
13637 lineno, expected, actual);
\r
13642 void abts_size_equal(abts_case *tc, size_t expected, size_t actual, int lineno)
\r
13645 if (tc->failed) return;
\r
13647 if (expected == actual) return;
\r
13652 fprintf(stderr, "Line %d: expected %lu, but saw %lu\n", lineno,
\r
13653 (unsigned long)expected, (unsigned long)actual);
\r
13658 void abts_str_equal(abts_case *tc, const char *expected, const char *actual, int lineno)
\r
13661 if (tc->failed) return;
\r
13663 if (!expected && !actual) return;
\r
13664 if (expected && actual)
\r
13665 if (!strcmp(expected, actual)) return;
\r
13669 fprintf(stderr, "Line %d: expected <%s>, but saw <%s>\n", lineno, expected, actual);
\r
13674 void abts_str_nequal(abts_case *tc, const char *expected, const char *actual,
\r
13675 size_t n, int lineno)
\r
13678 if (tc->failed) return;
\r
13680 if (!strncmp(expected, actual, n)) return;
\r
13684 fprintf(stderr, "Line %d: expected something other than <%s>, but saw <%s>\n",
\r
13685 lineno, expected, actual);
\r
13690 void abts_ptr_notnull(abts_case *tc, const void *ptr, int lineno)
\r
13693 if (tc->failed) return;
\r
13695 if (ptr != ((void*)0)) return;
\r
13699 fprintf(stderr, "Line %d: expected non-NULL, but saw NULL\n", lineno);
\r
13704 void abts_ptr_equal(abts_case *tc, const void *expected, const void *actual, int lineno)
\r
13707 if (tc->failed) return;
\r
13709 if (expected == actual) return;
\r
13713 fprintf(stderr, "Line %d: expected <%p>, but saw <%p>\n", lineno, expected, actual);
\r
13718 void abts_fail(abts_case *tc, const char *message, int lineno)
\r
13721 if (tc->failed) return;
\r
13725 fprintf(stderr, "Line %d: %s\n", lineno, message);
\r
13730 void abts_assert(abts_case *tc, const char *message, int condition, int lineno)
\r
13733 if (tc->failed) return;
\r
13735 if (condition) return;
\r
13739 fprintf(stderr, "Line %d: %s\n", lineno, message);
\r
13744 void abts_true(abts_case *tc, int condition, int lineno)
\r
13747 if (tc->failed) return;
\r
13749 if (condition) return;
\r
13753 fprintf(stderr, "Line %d: Condition is false, but expected true\n", lineno);
\r
13758 void abts_not_impl(abts_case *tc, const char *message, int lineno)
\r
13762 tc->suite->not_impl++;
\r
13764 fprintf(stderr, "Line %d: %s\n", lineno, message);
\r
13775 int fflush(FILE *stream){
\r
13779 int fprintf(FILE *stream, const char *format, ...){
\r
13783 void test_atomics_threaded_2(abts_case *tc, void *data)
\r
13785 apr_thread_t *t2[2];
\r
13793 rv = apr_thread_mutex_create(&thread_lock, 0x0, p);
\r
13794 (((rv == 0) && "Could not create lock") ? (void) (0) : __assert_fail ("(rv == 0) && \"Could not create lock\"", "main2.c", 45, __PRETTY_FUNCTION__));
\r
13796 for (i = 0; i < 2; i++) {
\r
13798 r2 = apr_thread_create(&t2[i], ((void*)0), thread_func_atomic, ((void*)0), p);
\r
13799 ((!r2 && "Failed creating threads") ? (void) (0) : __assert_fail ("!r2 && \"Failed creating threads\"", "main2.c", 50, __PRETTY_FUNCTION__));
\r
13802 for (i = 0; i < 2; i++) {
\r
13804 apr_thread_join(&s2, t2[i]);
\r
13806 ((s2 == exit_ret_val && "Invalid return value from thread_join") ? (void) (0) : __assert_fail ("s2 == exit_ret_val && \"Invalid return value from thread_join\"", "main2.c", 58, __PRETTY_FUNCTION__));
\r
13810 abts_int_equal(tc, 2 * 1, apr_atomic_read32(&atomic_ops), 62);
\r
13813 rv = apr_thread_mutex_destroy(thread_lock);
\r
13814 ((rv == 0 && "Failed creating threads") ? (void) (0) : __assert_fail ("rv == 0 && \"Failed creating threads\"", "main2.c", 65, __PRETTY_FUNCTION__));
\r
13817 int main(int argc, char *argv[]){
\r
13823 tc.suite = ((void*)0);
\r
13824 test_atomics_threaded_2(&tc,((void*)0));
\r