ReactOS  0.4.15-dev-2991-g632fa1c
stdlib.h
Go to the documentation of this file.
1 
6 #ifndef _INC_STDLIB
7 #define _INC_STDLIB
8 
9 #include <crtdefs.h>
10 #include <limits.h>
11 
12 #pragma pack(push,_CRT_PACKING)
13 
14 #ifdef __cplusplus
15 extern "C" {
16 #endif
17 
18 #ifndef MB_LEN_MAX
19 #define MB_LEN_MAX 5
20 #endif
21 
22 #define EXIT_SUCCESS 0
23 #define EXIT_FAILURE 1
24 
25 #ifndef _ONEXIT_T_DEFINED
26 #define _ONEXIT_T_DEFINED
27 
28  typedef int (__cdecl *_onexit_t)(void);
29 
30 #ifndef NO_OLDNAMES
31 #define onexit_t _onexit_t
32 #endif
33 #endif
34 
35 #ifndef _DIV_T_DEFINED
36 #define _DIV_T_DEFINED
37 
38  typedef struct _div_t {
39  int quot;
40  int rem;
41  } div_t;
42 
43  typedef struct _ldiv_t {
44  long quot;
45  long rem;
46  } ldiv_t;
47 #endif
48 
49 #ifndef _CRT_DOUBLE_DEC
50 #define _CRT_DOUBLE_DEC
51 
52 #pragma pack(4)
53  typedef struct {
54  unsigned char ld[10];
55  } _LDOUBLE;
56 #pragma pack()
57 
58 #define _PTR_LD(x) ((unsigned char *)(&(x)->ld))
59 
60  typedef struct {
61  double x;
62  } _CRT_DOUBLE;
63 
64  typedef struct {
65  float f;
66  } _CRT_FLOAT;
67 #if __MINGW_GNUC_PREREQ(4,4)
68 #pragma push_macro("long")
69 #undef long
70 #endif
71 
72  typedef struct {
73  long double x;
74  } _LONGDOUBLE;
75 
76 #if __MINGW_GNUC_PREREQ(4,4)
77 #pragma pop_macro("long")
78 #endif
79 
80 #pragma pack(4)
81  typedef struct {
82  unsigned char ld12[12];
83  } _LDBL12;
84 #pragma pack()
85 #endif
86 
87 #define RAND_MAX 0x7fff
88 
89 #ifndef MB_CUR_MAX
90 #define MB_CUR_MAX ___mb_cur_max_func()
91 #ifdef _M_CEE_PURE
93  #define __mb_cur_max (*__p___mb_cur_max())
94 #else /* !_M_CEE_PURE */
95  _CRTIMP extern int __mb_cur_max;
96 #endif /* !_M_CEE_PURE */
99 #endif /* !MB_CUR_MAX */
100 
101 #define __max(a,b) (((a) > (b)) ? (a) : (b))
102 #define __min(a,b) (((a) < (b)) ? (a) : (b))
103 
104 #define _MAX_PATH 260
105 #define _MAX_DRIVE 3
106 #define _MAX_DIR 256
107 #define _MAX_FNAME 256
108 #define _MAX_EXT 256
109 
110 #define _OUT_TO_DEFAULT 0
111 #define _OUT_TO_STDERR 1
112 #define _OUT_TO_MSGBOX 2
113 #define _REPORT_ERRMODE 3
114 
115 #define _WRITE_ABORT_MSG 0x1
116 #define _CALL_REPORTFAULT 0x2
117 
118 #define _MAX_ENV 32767
119 
121 
124 
125  typedef void (__cdecl *_invalid_parameter_handler)(const wchar_t *,const wchar_t *,const wchar_t *,unsigned int,uintptr_t);
128 
129 #include <errno.h>
130  _CRTIMP unsigned long *__cdecl __doserrno(void);
131 #define _doserrno (*__doserrno())
132  errno_t __cdecl _set_doserrno(_In_ unsigned long _Value);
133  errno_t __cdecl _get_doserrno(_Out_ unsigned long *_Value);
134 
135  _CRTIMP extern char *_sys_errlist[];
136  _CRTIMP extern int _sys_nerr;
137 
138 #if defined(_DLL) && defined(_M_IX86)
139  _CRTIMP int *__cdecl __p___argc(void);
140  _CRTIMP char ***__cdecl __p___argv(void);
141  _CRTIMP wchar_t ***__cdecl __p___wargv(void);
142  _CRTIMP char ***__cdecl __p__environ(void);
143  _CRTIMP wchar_t ***__cdecl __p__wenviron(void);
144  _CRTIMP char **__cdecl __p__pgmptr(void);
145  _CRTIMP wchar_t **__cdecl __p__wpgmptr(void);
146 #endif
147 
148 // FIXME: move inside _M_CEE_PURE section
149  _CRTIMP int *__cdecl __p___argc();
150  _CRTIMP char ***__cdecl __p___argv();
151  _CRTIMP wchar_t ***__cdecl __p___wargv();
152  _CRTIMP char ***__cdecl __p__environ();
153  _CRTIMP wchar_t ***__cdecl __p__wenviron();
154  _CRTIMP char **__cdecl __p__pgmptr();
155  _CRTIMP wchar_t **__cdecl __p__wpgmptr();
156 
157 #ifdef _M_CEE_PURE
158  #define __argv (*__p___argv())
159  #define __argc (*__p___argc())
160  #define __wargv (*__p___wargv())
161  #define _environ (*__p__environ())
162  #define _wenviron (*__p__wenviron())
163  #define _pgmptr (*__p__pgmptr())
164  #define _wpgmptr (*__p__wpgmptr())
165 #else /* !_M_CEE_PURE */
166  _CRTIMP extern int __argc;
167  _CRTIMP extern char **__argv;
168  _CRTIMP extern wchar_t **__wargv;
169  _CRTIMP extern char **_environ;
170  _CRTIMP extern wchar_t **_wenviron;
171  _CRTIMP extern char *_pgmptr;
172  _CRTIMP extern wchar_t *_wpgmptr;
173 #endif /* !_M_CEE_PURE */
174 
179 
180 #ifdef _M_CEE_PURE
181  _CRTIMP int* __cdecl __p__fmode();
182  #define _fmode (*__p__fmode())
183 #else
184  _CRTIMP extern int _fmode;
185 #endif /* !_M_CEE_PURE */
187  _CRTIMP errno_t __cdecl _get_fmode(_Out_ int *_PMode);
188 
189 #ifdef _M_CEE_PURE
190  _CRTIMP unsigned int* __cdecl __p__osplatform();
191  _CRTIMP unsigned int* __cdecl __p__osver();
192  _CRTIMP unsigned int* __cdecl __p__winver();
193  _CRTIMP unsigned int* __cdecl __p__winmajor();
194  _CRTIMP unsigned int* __cdecl __p__winminor();
195 #define _osplatform (*__p__osplatform())
196 #define _osver (*__p__osver())
197 #define _winver (*__p__winver())
198 #define _winmajor (*__p__winmajor())
199 #define _winminor (*__p__winminor())
200 #else /* !_M_CEE_PURE */
201  _CRTIMP extern unsigned int _osplatform;
202  _CRTIMP extern unsigned int _osver;
203  _CRTIMP extern unsigned int _winver;
204  _CRTIMP extern unsigned int _winmajor;
205  _CRTIMP extern unsigned int _winminor;
206 #endif /* !_M_CEE_PURE */
207 
208  errno_t __cdecl _get_osplatform(_Out_ unsigned int *_Value);
209  errno_t __cdecl _get_osver(_Out_ unsigned int *_Value);
210  errno_t __cdecl _get_winver(_Out_ unsigned int *_Value);
211  errno_t __cdecl _get_winmajor(_Out_ unsigned int *_Value);
212  errno_t __cdecl _get_winminor(_Out_ unsigned int *_Value);
213 
214 #ifndef _countof
215 #ifndef __cplusplus
216 #define _countof(_Array) (sizeof(_Array) / sizeof(_Array[0]))
217 #else
218  extern "C++" {
219  template <typename _CountofType,size_t _SizeOfArray>
220  char (*__countof_helper(/*UNALIGNED*/ _CountofType (&_Array)[_SizeOfArray]))[_SizeOfArray];
221 #define _countof(_Array) sizeof(*__countof_helper(_Array))
222  }
223 #endif
224 #endif
225 
226 #ifndef _CRT_TERMINATE_DEFINED
227 #define _CRT_TERMINATE_DEFINED
228  __declspec(noreturn) void __cdecl exit(_In_ int _Code);
229  _CRTIMP __declspec(noreturn) void __cdecl _exit(_In_ int _Code);
230 #if !defined __NO_ISOCEXT /* extern stub in static libmingwex.a */
231  /* C99 function name */
232  __declspec(noreturn) void __cdecl _Exit(int); /* Declare to get noreturn attribute. */
233  __CRT_INLINE void __cdecl _Exit(int status)
234  { _exit(status); }
235 #endif
236 #if __MINGW_GNUC_PREREQ(4,4)
237 #pragma push_macro("abort")
238 #undef abort
239 #endif
240  __declspec(noreturn) void __cdecl abort(void);
241 #if __MINGW_GNUC_PREREQ(4,4)
242 #pragma pop_macro("abort")
243 #endif
244 #endif
245 
246  _CRTIMP unsigned int __cdecl _set_abort_behavior(_In_ unsigned int _Flags, _In_ unsigned int _Mask);
247 
248 #ifndef _CRT_ABS_DEFINED
249 #define _CRT_ABS_DEFINED
250  int __cdecl abs(_In_ int _X);
251  long __cdecl labs(_In_ long _X);
252 #endif
253 
254 #if _INTEGRAL_MAX_BITS >= 64
256 #endif
257  int __cdecl atexit(void (__cdecl *)(void));
258 
259 #ifndef _CRT_ATOF_DEFINED
260 #define _CRT_ATOF_DEFINED
261 
263  double
264  __cdecl
265  atof(
266  _In_z_ const char *_String);
267 
269  double
270  __cdecl
271  _atof_l(
272  _In_z_ const char *_String,
274 
275 #endif /* _CRT_ATOF_DEFINED */
276 
278  int
279  __cdecl
280  atoi(
281  _In_z_ const char *_Str);
282 
284  _CRTIMP
285  int
286  __cdecl
287  _atoi_l(
288  _In_z_ const char *_Str,
290 
292  long
293  __cdecl
294  atol(
295  _In_z_ const char *_Str);
296 
298  _CRTIMP
299  long
300  __cdecl
301  _atol_l(
302  _In_z_ const char *_Str,
304 
305 #ifndef _CRT_ALGO_DEFINED
306 #define _CRT_ALGO_DEFINED
307 
309  void*
310  __cdecl
311  bsearch(
312  _In_ const void *_Key,
313  _In_reads_bytes_(_NumOfElements * _SizeOfElements) const void *_Base,
314  _In_ size_t _NumOfElements,
315  _In_ size_t _SizeOfElements,
316  _In_ int (__cdecl *_PtFuncCompare)(const void *,const void *));
317 
318  void
319  __cdecl
320  qsort(
321  _Inout_updates_bytes_(_NumOfElements * _SizeOfElements) _Post_readable_byte_size_(_NumOfElements * _SizeOfElements) void *_Base,
322  _In_ size_t _NumOfElements,
323  _In_ size_t _SizeOfElements,
324  _In_ int (__cdecl *_PtFuncCompare)(const void *,const void *));
325 
326 #endif /* _CRT_ALGO_DEFINED */
327 
328 #if !defined(__GNUC__) && !defined(__clang__)
329 
331  unsigned short
332  __cdecl
334  _In_ unsigned short _Short);
335 
337  unsigned long
338  __cdecl
340  _In_ unsigned long _Long);
341 
342 #if _INTEGRAL_MAX_BITS >= 64
345  unsigned __int64
346  __cdecl
348  _In_ unsigned __int64 _Int64);
349 #endif
350 
351 #endif /* !defined(__GNUC__) && !defined(__clang__) */
352 
354  div_t
355  __cdecl
356  div(
357  _In_ int _Numerator,
358  _In_ int _Denominator);
359 
361  char*
362  __cdecl
363  getenv(
364  _In_z_ const char *_VarName);
365 
366  _CRTIMP
367  char*
368  __cdecl
369  _itoa(
370  _In_ int _Value,
371  _Pre_notnull_ _Post_z_ char *_Dest,
372  _In_ int _Radix);
373 
374 #if _INTEGRAL_MAX_BITS >= 64
375 
377  _CRTIMP
378  char*
379  __cdecl
380  _i64toa(
381  _In_ __int64 _Val,
382  _Pre_notnull_ _Post_z_ char *_DstBuf,
383  _In_ int _Radix);
384 
386  _CRTIMP
387  char*
388  __cdecl
389  _ui64toa(
390  _In_ unsigned __int64 _Val,
391  _Pre_notnull_ _Post_z_ char *_DstBuf,
392  _In_ int _Radix);
393 
396  _CRTIMP
397  __int64
398  __cdecl
399  _atoi64(
400  _In_z_ const char *_String);
401 
404  _CRTIMP
405  __int64
406  __cdecl
407  _atoi64_l(
408  _In_z_ const char *_String,
410 
413  _CRTIMP
414  __int64
415  __cdecl
416  _strtoi64(
417  _In_z_ const char *_String,
418  _Out_opt_ _Deref_post_z_ char **_EndPtr,
419  _In_ int _Radix);
420 
423  _CRTIMP
424  __int64
425  __cdecl
426  _strtoi64_l(
427  _In_z_ const char *_String,
428  _Out_opt_ _Deref_post_z_ char **_EndPtr,
429  _In_ int _Radix,
431 
434  _CRTIMP
435  unsigned __int64
436  __cdecl
437  _strtoui64(
438  _In_z_ const char *_String,
439  _Out_opt_ _Deref_post_z_ char **_EndPtr,
440  _In_ int _Radix);
441 
444  _CRTIMP
445  unsigned __int64
446  __cdecl
447  _strtoui64_l(
448  _In_z_ const char *_String,
449  _Out_opt_ _Deref_post_z_ char **_EndPtr,
450  _In_ int _Radix,
452 
453 #endif /* _INTEGRAL_MAX_BITS >= 64 */
454 
456  ldiv_t
457  __cdecl
458  ldiv(
459  _In_ long _Numerator,
460  _In_ long _Denominator);
461 
462  _CRTIMP
463  char*
464  __cdecl
465  _ltoa(
466  _In_ long _Value,
467  _Pre_notnull_ _Post_z_ char *_Dest,
468  _In_ int _Radix);
469 
471  int
472  __cdecl
473  mblen(
475  _In_ size_t _MaxCount);
476 
478  _CRTIMP
479  int
480  __cdecl
481  _mblen_l(
483  _In_ size_t _MaxCount,
485 
487  _CRTIMP
488  size_t
489  __cdecl
490  _mbstrlen(
491  _In_z_ const char *_Str);
492 
494  _CRTIMP
495  size_t
496  __cdecl
497  _mbstrlen_l(
498  _In_z_ const char *_Str,
500 
501  _Success_(return>0)
503  _CRTIMP
504  size_t
505  __cdecl
506  _mbstrnlen(
507  _In_z_ const char *_Str,
508  _In_ size_t _MaxCount);
509 
511  _CRTIMP
512  size_t
513  __cdecl
514  _mbstrnlen_l(
515  _In_z_ const char *_Str,
516  _In_ size_t _MaxCount,
518 
519  int
520  __cdecl
521  mbtowc(
522  _Pre_notnull_ _Post_z_ wchar_t *_DstCh,
523  _In_reads_bytes_opt_(_SrcSizeInBytes) _Pre_opt_z_ const char *_SrcCh,
524  _In_ size_t _SrcSizeInBytes);
525 
526  _CRTIMP
527  int
528  __cdecl
529  _mbtowc_l(
530  _Pre_notnull_ _Post_z_ wchar_t *_DstCh,
531  _In_reads_bytes_opt_(_SrcSizeInBytes) _Pre_opt_z_ const char *_SrcCh,
532  _In_ size_t _SrcSizeInBytes,
534 
535  size_t
536  __cdecl
537  mbstowcs(
538  _Out_writes_opt_z_(_MaxCount) wchar_t *_Dest,
539  _In_z_ const char *_Source,
540  _In_ size_t _MaxCount);
541 
542  _CRTIMP
543  size_t
544  __cdecl
545  _mbstowcs_l(
546  _Out_writes_opt_z_(_MaxCount) wchar_t *_Dest,
547  _In_z_ const char *_Source,
548  _In_ size_t _MaxCount,
550 
552  int
553  __cdecl
554  rand(void);
555 
557  _CRTIMP
558  int
559  __cdecl
561  _In_ int _Mode);
562 
563  void
564  __cdecl
565  srand(
566  _In_ unsigned int _Seed);
567 
569  double
570  __cdecl
571  strtod(
572  _In_z_ const char *_Str,
573  _Out_opt_ _Deref_post_z_ char **_EndPtr);
574 
575  float
576  __cdecl
577  strtof(
578  const char *nptr,
579  char **endptr);
580 
581 #if !defined __NO_ISOCEXT /* in libmingwex.a */
582  float __cdecl strtof (const char * __restrict__, char ** __restrict__);
583  long double __cdecl strtold(const char * __restrict__, char ** __restrict__);
584 #endif /* __NO_ISOCEXT */
585 
587  _CRTIMP
588  double
589  __cdecl
590  _strtod_l(
591  _In_z_ const char *_Str,
592  _Out_opt_ _Deref_post_z_ char **_EndPtr,
594 
596  long
597  __cdecl
598  strtol(
599  _In_z_ const char *_Str,
600  _Out_opt_ _Deref_post_z_ char **_EndPtr,
601  _In_ int _Radix);
602 
604  _CRTIMP
605  long
606  __cdecl
607  _strtol_l(
608  _In_z_ const char *_Str,
609  _Out_opt_ _Deref_post_z_ char **_EndPtr,
610  _In_ int _Radix,
612 
614  unsigned long
615  __cdecl
616  strtoul(
617  _In_z_ const char *_Str,
618  _Out_opt_ _Deref_post_z_ char **_EndPtr,
619  _In_ int _Radix);
620 
622  _CRTIMP
623  unsigned long
624  __cdecl
625  _strtoul_l(
626  _In_z_ const char *_Str,
627  _Out_opt_ _Deref_post_z_ char **_EndPtr,
628  _In_ int _Radix,
630 
631 #ifndef _CRT_SYSTEM_DEFINED
632 #define _CRT_SYSTEM_DEFINED
633  int
634  __cdecl
635  system(
636  _In_opt_z_ const char *_Command);
637 #endif
638 
639  _CRTIMP
640  char*
641  __cdecl
642  _ultoa(
643  _In_ unsigned long _Value,
644  _Pre_notnull_ _Post_z_ char *_Dest,
645  _In_ int _Radix);
646 
647  int
648  __cdecl
649  wctomb(
650  _Out_writes_opt_z_(MB_LEN_MAX) char *_MbCh,
651  _In_ wchar_t _WCh);
652 
653  _CRTIMP
654  int
655  __cdecl
656  _wctomb_l(
657  _Pre_maybenull_ _Post_z_ char *_MbCh,
658  _In_ wchar_t _WCh,
660 
661  size_t
662  __cdecl
663  wcstombs(
664  _Out_writes_opt_z_(_MaxCount) char *_Dest,
665  _In_z_ const wchar_t *_Source,
666  _In_ size_t _MaxCount);
667 
668  _CRTIMP
669  size_t
670  __cdecl
671  _wcstombs_l(
672  _Out_writes_opt_z_(_MaxCount) char *_Dest,
673  _In_z_ const wchar_t *_Source,
674  _In_ size_t _MaxCount,
676 
677 #ifndef _CRT_ALLOCATION_DEFINED
678 #define _CRT_ALLOCATION_DEFINED
679 
683  void*
684  __cdecl
685  calloc(
686  _In_ size_t _NumOfElements,
688 
689  void
690  __cdecl
691  free(
692  _Pre_maybenull_ _Post_invalid_ void *_Memory);
693 
697  void*
698  __cdecl
699  malloc(
700  _In_ size_t _Size);
701 
702  _Success_(return != 0)
706  void*
707  __cdecl
708  realloc(
709  _Pre_maybenull_ _Post_invalid_ void *_Memory,
710  _In_ size_t _NewSize);
711 
712  _Success_(return != 0)
716  _CRTIMP
717  void*
718  __cdecl
719  _recalloc(
720  _Pre_maybenull_ _Post_invalid_ void *_Memory,
721  _In_ size_t _Count,
722  _In_ size_t _Size);
723 
724 /* Make sure that X86intrin.h doesn't produce here collisions. */
725 #if (!defined (_XMMINTRIN_H_INCLUDED) && !defined (_MM_MALLOC_H_INCLUDED)) || defined(_aligned_malloc)
726 #pragma push_macro("_aligned_free")
727 #pragma push_macro("_aligned_malloc")
728 #undef _aligned_free
729 #undef _aligned_malloc
730 
731  _CRTIMP
732  void
733  __cdecl
735  _Pre_maybenull_ _Post_invalid_ void *_Memory);
736 
740  _CRTIMP
741  void*
742  __cdecl
744  _In_ size_t _Size,
745  _In_ size_t _Alignment);
746 
747 #pragma pop_macro("_aligned_free")
748 #pragma pop_macro("_aligned_malloc")
749 #endif
750 
754  _CRTIMP
755  void*
756  __cdecl
758  _In_ size_t _Size,
759  _In_ size_t _Alignment,
760  _In_ size_t _Offset);
761 
762  _Success_(return != 0)
766  _CRTIMP
767  void*
768  __cdecl
770  _Pre_maybenull_ _Post_invalid_ void *_Memory,
771  _In_ size_t _Size,
772  _In_ size_t _Alignment);
773 
774  _Success_(return != 0)
778  _CRTIMP
779  void*
780  __cdecl
781  _aligned_recalloc(
782  _Pre_maybenull_ _Post_invalid_ void *_Memory,
783  _In_ size_t _Count,
784  _In_ size_t _Size,
785  _In_ size_t _Alignment);
786 
787  _Success_(return != 0)
791  _CRTIMP
792  void*
793  __cdecl
795  _Pre_maybenull_ _Post_invalid_ void *_Memory,
796  _In_ size_t _Size,
797  _In_ size_t _Alignment,
798  _In_ size_t _Offset);
799 
803  _CRTIMP
804  void*
805  __cdecl
806  _aligned_offset_recalloc(
807  _Pre_maybenull_ _Post_invalid_ void *_Memory,
808  _In_ size_t _Count,
809  _In_ size_t _Size,
810  _In_ size_t _Alignment,
811  _In_ size_t _Offset);
812 
813 #endif /* _CRT_ALLOCATION_DEFINED */
814 
815 #ifndef _WSTDLIB_DEFINED
816 #define _WSTDLIB_DEFINED
817 
818  _CRTIMP
819  wchar_t*
820  __cdecl
821  _itow(
822  _In_ int _Value,
823  _Pre_notnull_ _Post_z_ wchar_t *_Dest,
824  _In_ int _Radix);
825 
826  _CRTIMP
827  wchar_t*
828  __cdecl
829  _ltow(
830  _In_ long _Value,
831  _Pre_notnull_ _Post_z_ wchar_t *_Dest,
832  _In_ int _Radix);
833 
834  _CRTIMP
835  wchar_t*
836  __cdecl
837  _ultow(
838  _In_ unsigned long _Value,
839  _Pre_notnull_ _Post_z_ wchar_t *_Dest,
840  _In_ int _Radix);
841 
843  double
844  __cdecl
845  wcstod(
846  _In_z_ const wchar_t *_Str,
847  _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr);
848 
849  float
850  __cdecl
851  wcstof(
852  const wchar_t *nptr,
853  wchar_t **endptr);
854 
855 #if !defined __NO_ISOCEXT /* in libmingwex.a */
856  float __cdecl wcstof( const wchar_t * __restrict__, wchar_t ** __restrict__);
857  long double __cdecl wcstold(const wchar_t * __restrict__, wchar_t ** __restrict__);
858 #endif /* __NO_ISOCEXT */
859 
861  _CRTIMP
862  double
863  __cdecl
864  _wcstod_l(
865  _In_z_ const wchar_t *_Str,
866  _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr,
868 
870  long
871  __cdecl
872  wcstol(
873  _In_z_ const wchar_t *_Str,
874  _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr,
875  _In_ int _Radix);
876 
878  _CRTIMP
879  long
880  __cdecl
881  _wcstol_l(
882  _In_z_ const wchar_t *_Str,
883  _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr,
884  _In_ int _Radix,
886 
888  unsigned long
889  __cdecl
890  wcstoul(
891  _In_z_ const wchar_t *_Str,
892  _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr,
893  _In_ int _Radix);
894 
896  _CRTIMP
897  unsigned long
898  __cdecl
899  _wcstoul_l(
900  _In_z_ const wchar_t *_Str,
901  _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr,
902  _In_ int _Radix,
904 
906  _CRTIMP
907  wchar_t*
908  __cdecl
909  _wgetenv(
910  _In_z_ const wchar_t *_VarName);
911 
912 #ifndef _CRT_WSYSTEM_DEFINED
913 #define _CRT_WSYSTEM_DEFINED
914  _CRTIMP
915  int
916  __cdecl
917  _wsystem(
918  _In_opt_z_ const wchar_t *_Command);
919 #endif
920 
922  _CRTIMP
923  double
924  __cdecl
925  _wtof(
926  _In_z_ const wchar_t *_Str);
927 
929  _CRTIMP
930  double
931  __cdecl
932  _wtof_l(
933  _In_z_ const wchar_t *_Str,
935 
937  _CRTIMP
938  int
939  __cdecl
940  _wtoi(
941  _In_z_ const wchar_t *_Str);
942 
944  _CRTIMP
945  int
946  __cdecl
947  _wtoi_l(
948  _In_z_ const wchar_t *_Str,
950 
952  _CRTIMP
953  long
954  __cdecl
955  _wtol(
956  _In_z_ const wchar_t *_Str);
957 
959  _CRTIMP
960  long
961  __cdecl
962  _wtol_l(
963  _In_z_ const wchar_t *_Str,
965 
966 #if _INTEGRAL_MAX_BITS >= 64
967 
969  _CRTIMP
970  wchar_t*
971  __cdecl
972  _i64tow(
973  _In_ __int64 _Val,
974  _Pre_notnull_ _Post_z_ wchar_t *_DstBuf,
975  _In_ int _Radix);
976 
978  _CRTIMP
979  wchar_t*
980  __cdecl
981  _ui64tow(
982  _In_ unsigned __int64 _Val,
983  _Pre_notnull_ _Post_z_ wchar_t *_DstBuf,
984  _In_ int _Radix);
985 
988  _CRTIMP
989  __int64
990  __cdecl
991  _wtoi64(
992  _In_z_ const wchar_t *_Str);
993 
996  _CRTIMP
997  __int64
998  __cdecl
999  _wtoi64_l(
1000  _In_z_ const wchar_t *_Str,
1002 
1005  _CRTIMP
1006  __int64
1007  __cdecl
1008  _wcstoi64(
1009  _In_z_ const wchar_t *_Str,
1010  _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr,
1011  _In_ int _Radix);
1012 
1015  _CRTIMP
1016  __int64
1017  __cdecl
1018  _wcstoi64_l(
1019  _In_z_ const wchar_t *_Str,
1020  _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr,
1021  _In_ int _Radix,
1023 
1026  _CRTIMP
1027  unsigned __int64
1028  __cdecl
1029  _wcstoui64(
1030  _In_z_ const wchar_t *_Str,
1031  _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr,
1032  _In_ int _Radix);
1033 
1036  _CRTIMP
1037  unsigned __int64
1038  __cdecl
1039  _wcstoui64_l(
1040  _In_z_ const wchar_t *_Str,
1041  _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr,
1042  _In_ int _Radix,
1044 
1045 #endif /* _INTEGRAL_MAX_BITS >= 64 */
1046 
1047 #endif /* _WSTDLIB_DEFINED */
1048 
1049 #ifndef _POSIX_
1050 #define _CVTBUFSIZE (309+40)
1051 
1053  _CRTIMP
1054  char*
1055  __cdecl
1056  _fullpath(
1057  _Out_writes_opt_z_(_SizeInBytes) char *_FullPath,
1058  _In_z_ const char *_Path,
1059  _In_ size_t _SizeInBytes);
1060 
1062  _CRTIMP
1063  char*
1064  __cdecl
1065  _ecvt(
1066  _In_ double _Val,
1067  _In_ int _NumOfDigits,
1068  _Out_ int *_PtDec,
1069  _Out_ int *_PtSign);
1070 
1072  _CRTIMP
1073  char*
1074  __cdecl
1075  _fcvt(
1076  _In_ double _Val,
1077  _In_ int _NumOfDec,
1078  _Out_ int *_PtDec,
1079  _Out_ int *_PtSign);
1080 
1081  _CRTIMP
1082  char*
1083  __cdecl
1084  _gcvt(
1085  _In_ double _Val,
1086  _In_ int _NumOfDigits,
1087  _Pre_notnull_ _Post_z_ char *_DstBuf);
1088 
1090  _CRTIMP
1091  int
1092  __cdecl
1093  _atodbl(
1094  _Out_ _CRT_DOUBLE *_Result,
1095  _In_z_ char *_Str);
1096 
1098  _CRTIMP
1099  int
1100  __cdecl
1101  _atoldbl(
1102  _Out_ _LDOUBLE *_Result,
1103  _In_z_ char *_Str);
1104 
1106  _CRTIMP
1107  int
1108  __cdecl
1109  _atoflt(
1110  _Out_ _CRT_FLOAT *_Result,
1111  _In_z_ char *_Str);
1112 
1114  _CRTIMP
1115  int
1116  __cdecl
1117  _atodbl_l(
1118  _Out_ _CRT_DOUBLE *_Result,
1119  _In_z_ char *_Str,
1121 
1123  _CRTIMP
1124  int
1125  __cdecl
1126  _atoldbl_l(
1127  _Out_ _LDOUBLE *_Result,
1128  _In_z_ char *_Str,
1130 
1132  _CRTIMP
1133  int
1134  __cdecl
1135  _atoflt_l(
1136  _Out_ _CRT_FLOAT *_Result,
1137  _In_z_ char *_Str,
1139 
1141  unsigned long
1142  __cdecl
1143  _lrotl(
1144  _In_ unsigned long _Val,
1145  _In_ int _Shift);
1146 
1148  unsigned long
1149  __cdecl
1150  _lrotr(
1151  _In_ unsigned long _Val,
1152  _In_ int _Shift);
1153 
1154  _CRTIMP
1155  void
1156  __cdecl
1157  _makepath(
1158  _Pre_notnull_ _Post_z_ char *_Path,
1159  _In_opt_z_ const char *_Drive,
1160  _In_opt_z_ const char *_Dir,
1161  _In_opt_z_ const char *_Filename,
1162  _In_opt_z_ const char *_Ext);
1163 
1164  _onexit_t
1165  __cdecl
1166  _onexit(
1167  _In_opt_ _onexit_t _Func);
1168 
1169 #ifndef _CRT_PERROR_DEFINED
1170 #define _CRT_PERROR_DEFINED
1171  void
1172  __cdecl
1173  perror(
1174  _In_opt_z_ const char *_ErrMsg);
1175 #endif
1176 
1178  _CRTIMP
1179  int
1180  __cdecl
1181  _putenv(
1182  _In_z_ const char *_EnvString);
1183 
1184 #if !defined(__clang__)
1185 
1187  unsigned int
1188  __cdecl
1189  _rotl(
1190  _In_ unsigned int _Val,
1191  _In_ int _Shift);
1192 
1193 #if _INTEGRAL_MAX_BITS >= 64
1196  unsigned __int64
1197  __cdecl
1198  _rotl64(
1199  _In_ unsigned __int64 _Val,
1200  _In_ int _Shift);
1201 #endif
1202 
1204  unsigned int
1205  __cdecl
1206  _rotr(
1207  _In_ unsigned int _Val,
1208  _In_ int _Shift);
1209 
1210 #if _INTEGRAL_MAX_BITS >= 64
1213  unsigned __int64
1214  __cdecl
1215  _rotr64(
1216  _In_ unsigned __int64 _Val,
1217  _In_ int _Shift);
1218 #endif
1219 
1220 #endif /* !defined(__clang__) */
1221 
1222  _CRTIMP
1223  void
1224  __cdecl
1225  _searchenv(
1226  _In_z_ const char *_Filename,
1227  _In_z_ const char *_EnvVar,
1228  _Pre_notnull_ _Post_z_ char *_ResultPath);
1229 
1230  _CRTIMP
1231  void
1232  __cdecl
1233  _splitpath(
1234  _In_z_ const char *_FullPath,
1235  _Pre_maybenull_ _Post_z_ char *_Drive,
1236  _Pre_maybenull_ _Post_z_ char *_Dir,
1237  _Pre_maybenull_ _Post_z_ char *_Filename,
1238  _Pre_maybenull_ _Post_z_ char *_Ext);
1239 
1240  _CRTIMP
1241  void
1242  __cdecl
1243  _swab(
1246  int _SizeInBytes);
1247 
1248 #ifndef _WSTDLIBP_DEFINED
1249 #define _WSTDLIBP_DEFINED
1250 
1252  _CRTIMP
1253  wchar_t*
1254  __cdecl
1255  _wfullpath(
1256  _Out_writes_opt_z_(_SizeInWords) wchar_t *_FullPath,
1257  _In_z_ const wchar_t *_Path,
1258  _In_ size_t _SizeInWords);
1259 
1260  _CRTIMP
1261  void
1262  __cdecl
1263  _wmakepath(
1264  _Pre_notnull_ _Post_z_ wchar_t *_ResultPath,
1265  _In_opt_z_ const wchar_t *_Drive,
1266  _In_opt_z_ const wchar_t *_Dir,
1267  _In_opt_z_ const wchar_t *_Filename,
1268  _In_opt_z_ const wchar_t *_Ext);
1269 
1270 #ifndef _CRT_WPERROR_DEFINED
1271 #define _CRT_WPERROR_DEFINED
1272  _CRTIMP
1273  void
1274  __cdecl
1275  _wperror(
1276  _In_opt_z_ const wchar_t *_ErrMsg);
1277 #endif
1278 
1280  _CRTIMP
1281  int
1282  __cdecl
1283  _wputenv(
1284  _In_z_ const wchar_t *_EnvString);
1285 
1286  _CRTIMP
1287  void
1288  __cdecl
1289  _wsearchenv(
1290  _In_z_ const wchar_t *_Filename,
1291  _In_z_ const wchar_t *_EnvVar,
1292  _Pre_notnull_ _Post_z_ wchar_t *_ResultPath);
1293 
1294  _CRTIMP
1295  void
1296  __cdecl
1297  _wsplitpath(
1298  _In_z_ const wchar_t *_FullPath,
1299  _Pre_maybenull_ _Post_z_ wchar_t *_Drive,
1300  _Pre_maybenull_ _Post_z_ wchar_t *_Dir,
1301  _Pre_maybenull_ _Post_z_ wchar_t *_Filename,
1302  _Pre_maybenull_ _Post_z_ wchar_t *_Ext);
1303 
1304 #endif /* _WSTDLIBP_DEFINED */
1305 
1306  _CRTIMP
1308  void
1309  __cdecl
1310  _beep(
1311  _In_ unsigned _Frequency,
1312  _In_ unsigned _Duration);
1313 
1314  /* Not to be confused with _set_error_mode (int). */
1315  _CRTIMP
1317  void
1318  __cdecl
1319  _seterrormode(
1320  _In_ int _Mode);
1321 
1322  _CRTIMP
1324  void
1325  __cdecl
1326  _sleep(
1327  _In_ unsigned long _Duration);
1328 
1329 #endif /* _POSIX_ */
1330 
1331 #ifndef NO_OLDNAMES
1332 #ifndef _POSIX_
1333 #if 0
1334 #ifndef __cplusplus
1335 #ifndef NOMINMAX
1336 #ifndef max
1337 #define max(a,b) (((a) > (b)) ? (a) : (b))
1338 #endif
1339 #ifndef min
1340 #define min(a,b) (((a) < (b)) ? (a) : (b))
1341 #endif
1342 #endif /* NOMINMAX */
1343 #endif /* __cplusplus */
1344 #endif
1345 
1346 #define sys_errlist _sys_errlist
1347 #define sys_nerr _sys_nerr
1348 #define environ _environ
1349 
1351  _CRTIMP
1352  char*
1353  __cdecl
1354  ecvt(
1355  _In_ double _Val,
1356  _In_ int _NumOfDigits,
1357  _Out_ int *_PtDec,
1358  _Out_ int *_PtSign);
1359 
1361  _CRTIMP
1362  char*
1363  __cdecl
1364  fcvt(
1365  _In_ double _Val,
1366  _In_ int _NumOfDec,
1367  _Out_ int *_PtDec,
1368  _Out_ int *_PtSign);
1369 
1370  _CRTIMP
1371  char*
1372  __cdecl
1373  gcvt(
1374  _In_ double _Val,
1375  _In_ int _NumOfDigits,
1376  _Pre_notnull_ _Post_z_ char *_DstBuf);
1377 
1378  _CRTIMP
1379  char*
1380  __cdecl
1381  itoa(
1382  _In_ int _Val,
1383  _Pre_notnull_ _Post_z_ char *_DstBuf,
1384  _In_ int _Radix);
1385 
1386  _CRTIMP
1387  char*
1388  __cdecl
1389  ltoa(
1390  _In_ long _Val,
1391  _Pre_notnull_ _Post_z_ char *_DstBuf,
1392  _In_ int _Radix);
1393 
1395  _CRTIMP
1396  int
1397  __cdecl
1398  putenv(
1399  _In_z_ const char *_EnvString);
1400 
1401  _CRTIMP
1402  void
1403  __cdecl
1404  swab(
1405  _Inout_updates_z_(_SizeInBytes) char *_Buf1,
1406  _Inout_updates_z_(_SizeInBytes) char *_Buf2,
1407  _In_ int _SizeInBytes);
1408 
1409  _CRTIMP
1410  char*
1411  __cdecl
1412  ultoa(
1413  _In_ unsigned long _Val,
1414  _Pre_notnull_ _Post_z_ char *_Dstbuf,
1415  _In_ int _Radix);
1416 
1417  onexit_t
1418  __cdecl
1419  onexit(
1420  _In_opt_ onexit_t _Func);
1421 
1422 #endif /* _POSIX_ */
1423 #endif /* NO_OLDNAMES */
1424 
1425 #if !defined __NO_ISOCEXT /* externs in static libmingwex.a */
1426 
1427  __MINGW_EXTENSION typedef struct { long long quot, rem; } lldiv_t;
1428 
1430 
1431 #if defined(_MSC_VER)
1432  _Check_return_ long long __cdecl llabs(_In_ long long _j);
1433  #pragma function(llabs)
1434 #endif
1435  __MINGW_EXTENSION __CRT_INLINE long long __cdecl llabs(_In_ long long _j) { return (_j >= 0 ? _j : -_j); }
1436 
1437  __MINGW_EXTENSION long long __cdecl strtoll(const char* __restrict__, char** __restrict, int);
1438  __MINGW_EXTENSION unsigned long long __cdecl strtoull(const char* __restrict__, char** __restrict__, int);
1439 
1440  /* these are stubs for MS _i64 versions */
1441  __MINGW_EXTENSION long long __cdecl atoll (const char *);
1442 
1443 #ifndef __STRICT_ANSI__
1444  __MINGW_EXTENSION long long __cdecl wtoll (const wchar_t *);
1445  __MINGW_EXTENSION char *__cdecl lltoa (long long, char *, int);
1446  __MINGW_EXTENSION char *__cdecl ulltoa (unsigned long long , char *, int);
1447  __MINGW_EXTENSION wchar_t *__cdecl lltow (long long, wchar_t *, int);
1448  __MINGW_EXTENSION wchar_t *__cdecl ulltow (unsigned long long, wchar_t *, int);
1449 
1450  /* __CRT_INLINE using non-ansi functions */
1451  __MINGW_EXTENSION __CRT_INLINE long long __cdecl atoll (const char * _c) { return _atoi64 (_c); }
1452  __MINGW_EXTENSION __CRT_INLINE char *__cdecl lltoa (long long _n, char * _c, int _i) { return _i64toa (_n, _c, _i); }
1453  __MINGW_EXTENSION __CRT_INLINE char *__cdecl ulltoa (unsigned long long _n, char * _c, int _i) { return _ui64toa (_n, _c, _i); }
1454  __MINGW_EXTENSION __CRT_INLINE long long __cdecl wtoll (const wchar_t * _w) { return _wtoi64 (_w); }
1455  __MINGW_EXTENSION __CRT_INLINE wchar_t *__cdecl lltow (long long _n, wchar_t * _w, int _i) { return _i64tow (_n, _w, _i); }
1456  __MINGW_EXTENSION __CRT_INLINE wchar_t *__cdecl ulltow (unsigned long long _n, wchar_t * _w, int _i) { return _ui64tow (_n, _w, _i); }
1457 #endif /* (__STRICT_ANSI__) */
1458 
1459 #endif /* !__NO_ISOCEXT */
1460 
1461 #ifdef __cplusplus
1462 }
1463 #endif
1464 
1465 #pragma pack(pop)
1466 
1467 #include <sec_api/stdlib_s.h>
1468 #endif
_CRTIMP void __cdecl _swab(_Inout_updates_(_SizeInBytes) _Post_readable_size_(_SizeInBytes) char *_Buf1, _Inout_updates_(_SizeInBytes) _Post_readable_size_(_SizeInBytes) char *_Buf2, int _SizeInBytes)
_CRTIMP wchar_t *__cdecl _ltow(_In_ long _Value, _Pre_notnull_ _Post_z_ wchar_t *_Dest, _In_ int _Radix)
_CRTIMP int __cdecl _wsystem(_In_opt_z_ const wchar_t *_Command)
_CRTIMP void __cdecl _wmakepath(_Pre_notnull_ _Post_z_ wchar_t *_ResultPath, _In_opt_z_ const wchar_t *_Drive, _In_opt_z_ const wchar_t *_Dir, _In_opt_z_ const wchar_t *_Filename, _In_opt_z_ const wchar_t *_Ext)
unsigned int * __p__winminor(void)
Definition: environ.c:508
_Check_return_ double __cdecl atof(_In_z_ const char *_String)
errno_t __cdecl _get_osplatform(_Out_ unsigned int *_Value)
int __cdecl wctomb(_Out_writes_opt_z_(MB_LEN_MAX) char *_MbCh, _In_ wchar_t _WCh)
__MINGW_EXTENSION _Check_return_ unsigned __int64 __cdecl _rotr64(_In_ unsigned __int64 _Val, _In_ int _Shift)
_CRTIMP wchar_t ***__cdecl __p__wenviron()
Definition: environ.c:392
_CRTIMP void __cdecl _aligned_free(_Pre_maybenull_ _Post_invalid_ void *_Memory)
_Check_return_ _Ret_maybenull_ _In_ size_t _Alignment
Definition: stdlib.h:745
return
Definition: dirsup.c:529
_CRTIMP errno_t __cdecl _set_fmode(_In_ int _Mode)
_CRTIMP wchar_t *__cdecl _ultow(_In_ unsigned long _Value, _Pre_notnull_ _Post_z_ wchar_t *_Dest, _In_ int _Radix)
_Check_return_ _CRTIMP int __cdecl _mblen_l(_In_reads_bytes_opt_(_MaxCount) _Pre_opt_z_ const char *_Ch, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale)
_CRTIMP char ** __argv
Definition: getargs.c:18
errno_t __cdecl _get_winmajor(_Out_ unsigned int *_Value)
_Check_return_ _CRTIMP int __cdecl putenv(_In_z_ const char *_EnvString)
_Check_return_ unsigned long __cdecl _lrotl(_In_ unsigned long _Val, _In_ int _Shift)
_Check_return_ _CRTIMP int __cdecl _atoi_l(_In_z_ const char *_Str, _In_opt_ _locale_t _Locale)
_Check_return_ wchar_t _Ch
Definition: string.h:640
_Check_return_ _CRTIMP char *__cdecl _fullpath(_Out_writes_opt_z_(_SizeInBytes) char *_FullPath, _In_z_ const char *_Path, _In_ size_t _SizeInBytes)
long double __cdecl wcstold(const wchar_t *__restrict__, wchar_t **__restrict__)
struct png_info_def **typedef void(__cdecl typeof(png_destroy_read_struct))(struct png_struct_def **
Definition: typeof.h:49
#define _In_opt_
Definition: ms_sal.h:309
_Check_return_ void *__cdecl bsearch(_In_ const void *_Key, _In_reads_bytes_(_NumOfElements *_SizeOfElements) const void *_Base, _In_ size_t _NumOfElements, _In_ size_t _SizeOfElements, _In_ int(__cdecl *_PtFuncCompare)(const void *, const void *))
unsigned int * __p__winmajor(void)
Definition: environ.c:500
#define _Post_readable_size_(size)
Definition: ms_sal.h:649
_CRTIMP _purecall_handler __cdecl _get_purecall_handler(void)
_Check_return_ _CRTIMP long __cdecl _strtol_l(_In_z_ const char *_Str, _Out_opt_ _Deref_post_z_ char **_EndPtr, _In_ int _Radix, _In_opt_ _locale_t _Locale)
#define __cdecl
Definition: accygwin.h:79
_CRTIMP char ** _environ
Definition: environ.c:22
#define _In_opt_z_
Definition: ms_sal.h:314
#define _Out_
Definition: ms_sal.h:345
_CRTIMP void __cdecl _makepath(_Pre_notnull_ _Post_z_ char *_Path, _In_opt_z_ const char *_Drive, _In_opt_z_ const char *_Dir, _In_opt_z_ const char *_Filename, _In_opt_z_ const char *_Ext)
_Check_return_ double __cdecl strtod(_In_z_ const char *_Str, _Out_opt_ _Deref_post_z_ char **_EndPtr)
size_t __cdecl mbstowcs(_Out_writes_opt_z_(_MaxCount) wchar_t *_Dest, _In_z_ const char *_Source, _In_ size_t _MaxCount)
__MINGW_EXTENSION _Check_return_ _CRTIMP __int64 __cdecl _atoi64(_In_z_ const char *_String)
_In_ size_t _In_ size_t _Size
Definition: stdlib.h:721
char * realloc()
#define _CRTIMP
Definition: crtdefs.h:72
float __cdecl wcstof(const wchar_t *nptr, wchar_t **endptr)
_Check_return_ _CRTIMP int __cdecl _wtoi(_In_z_ const wchar_t *_Str)
_CRTIMP unsigned long *__cdecl __doserrno(void)
Definition: errno.c:27
int __cdecl system(_In_opt_z_ const char *_Command)
void __cdecl qsort(_Inout_updates_bytes_(_NumOfElements *_SizeOfElements) _Post_readable_byte_size_(_NumOfElements *_SizeOfElements) void *_Base, _In_ size_t _NumOfElements, _In_ size_t _SizeOfElements, _In_ int(__cdecl *_PtFuncCompare)(const void *, const void *))
_CRTIMP char **__cdecl __p__pgmptr()
Definition: environ.c:454
_CRTIMP unsigned int _winminor
Definition: environ.c:12
__MINGW_EXTENSION _Check_return_ _CRTIMP unsigned __int64 __cdecl _wcstoui64(_In_z_ const wchar_t *_Str, _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, _In_ int _Radix)
_CRTIMP int __cdecl _mbtowc_l(_Pre_notnull_ _Post_z_ wchar_t *_DstCh, _In_reads_bytes_opt_(_SrcSizeInBytes) _Pre_opt_z_ const char *_SrcCh, _In_ size_t _SrcSizeInBytes, _In_opt_ _locale_t _Locale)
_CRTIMP int *__cdecl __p___argc()
Definition: getargs.c:475
errno_t __cdecl _get_winminor(_Out_ unsigned int *_Value)
void __cdecl srand(_In_ unsigned int _Seed)
_CRTIMP int _sys_nerr
Definition: strerror.c:79
_CRTIMP size_t __cdecl _wcstombs_l(_Out_writes_opt_z_(_MaxCount) char *_Dest, _In_z_ const wchar_t *_Source, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale)
_CRTIMP unsigned int _osplatform
Definition: environ.c:10
_CRTIMP wchar_t ***__cdecl __p___wargv()
Definition: getargs.c:491
_Check_return_ _Ret_maybenull_ _Post_writable_byte_size_(_NumOfElements *_SizeOfElements) void *__cdecl calloc(_In_ size_t _NumOfElements
_In_ size_t _Count
Definition: stdlib.h:721
__MINGW_EXTENSION _CRTIMP char *__cdecl _i64toa(_In_ __int64 _Val, _Pre_notnull_ _Post_z_ char *_DstBuf, _In_ int _Radix)
_CRTIMP void __cdecl _splitpath(_In_z_ const char *_FullPath, _Pre_maybenull_ _Post_z_ char *_Drive, _Pre_maybenull_ _Post_z_ char *_Dir, _Pre_maybenull_ _Post_z_ char *_Filename, _Pre_maybenull_ _Post_z_ char *_Ext)
#define onexit_t
Definition: stdlib.h:31
int(__cdecl * _onexit_t)(void)
Definition: stdlib.h:28
_CRTIMP wchar_t *__cdecl _itow(_In_ int _Value, _Pre_notnull_ _Post_z_ wchar_t *_Dest, _In_ int _Radix)
__MINGW_EXTENSION long long __cdecl wtoll(const wchar_t *)
Definition: stdlib.h:1454
_CRTIMP unsigned int _winver
Definition: environ.c:14
_Check_return_ long __cdecl wcstol(_In_z_ const wchar_t *_Str, _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, _In_ int _Radix)
_Check_return_ unsigned long __cdecl wcstoul(_In_z_ const wchar_t *_Str, _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, _In_ int _Radix)
_CRTIMP char ***__cdecl __p___argv()
Definition: getargs.c:483
__MINGW_EXTENSION _Check_return_ lldiv_t __cdecl lldiv(_In_ long long, _In_ long long)
int *__cdecl __p___mb_cur_max(void)
Definition: environ.c:430
_Check_return_ _CRTIMP unsigned long __cdecl _strtoul_l(_In_z_ const char *_Str, _Out_opt_ _Deref_post_z_ char **_EndPtr, _In_ int _Radix, _In_opt_ _locale_t _Locale)
__MINGW_EXTENSION _Check_return_ _CRTIMP unsigned __int64 __cdecl _wcstoui64_l(_In_z_ const wchar_t *_Str, _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, _In_ int _Radix, _In_opt_ _locale_t _Locale)
__MINGW_EXTENSION _Check_return_ _CRTIMP __int64 __cdecl _strtoi64(_In_z_ const char *_String, _Out_opt_ _Deref_post_z_ char **_EndPtr, _In_ int _Radix)
_Check_return_ _CRTIMP double __cdecl _wcstod_l(_In_z_ const wchar_t *_Str, _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP unsigned long __cdecl _wcstoul_l(_In_z_ const wchar_t *_Str, _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, _In_ int _Radix, _In_opt_ _locale_t _Locale)
void __cdecl perror(_In_opt_z_ const char *_ErrMsg)
void *CDECL _aligned_offset_malloc(size_t size, size_t alignment, size_t offset)
Definition: heap.c:372
errno_t __cdecl _get_osver(_Out_ unsigned int *_Value)
_invalid_parameter_handler __cdecl _set_invalid_parameter_handler(_In_opt_ _invalid_parameter_handler _Handler)
__MINGW_EXTENSION long long __cdecl atoll(const char *)
Definition: stdlib.h:1451
__MINGW_EXTENSION _Check_return_ _CRTIMP __int64 __cdecl _wtoi64(_In_z_ const wchar_t *_Str)
int __cdecl atexit(void(__cdecl *)(void))
Definition: atonexit.c:97
__MINGW_EXTENSION _CRTIMP wchar_t *__cdecl _i64tow(_In_ __int64 _Val, _Pre_notnull_ _Post_z_ wchar_t *_DstBuf, _In_ int _Radix)
_Check_return_ _CRTIMP int __cdecl _atoflt(_Out_ _CRT_FLOAT *_Result, _In_z_ char *_Str)
_onexit_t __cdecl _onexit(_In_opt_ _onexit_t _Func)
_Check_return_ _CRTIMP long __cdecl _wcstol_l(_In_z_ const wchar_t *_Str, _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, _In_ int _Radix, _In_opt_ _locale_t _Locale)
_CRTIMP wchar_t ** _wenviron
Definition: environ.c:23
_Check_return_ _CRTIMP size_t __cdecl _mbstrlen_l(_In_z_ const char *_Str, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP wchar_t *__cdecl _wfullpath(_Out_writes_opt_z_(_SizeInWords) wchar_t *_FullPath, _In_z_ const wchar_t *_Path, _In_ size_t _SizeInWords)
_Check_return_ _CRTIMP int __cdecl _atoldbl_l(_Out_ _LDOUBLE *_Result, _In_z_ char *_Str, _In_opt_ _locale_t _Locale)
int __cdecl abs(_In_ int _X)
double x
Definition: stdlib.h:61
__MINGW_EXTENSION _Check_return_ _CRTIMP __int64 __cdecl _atoi64_l(_In_z_ const char *_String, _In_opt_ _locale_t _Locale)
unsigned int *__cdecl __p__fmode(void)
Definition: fmode.c:9
void(__cdecl * _purecall_handler)(void)
Definition: stdlib.h:120
_Check_return_ double __cdecl _atof_l(_In_z_ const char *_String, _In_opt_ _locale_t _Locale)
#define _X(x)
Definition: CString.cpp:149
_CRTIMP char *__cdecl _ultoa(_In_ unsigned long _Value, _Pre_notnull_ _Post_z_ char *_Dest, _In_ int _Radix)
_Check_return_ int __cdecl rand(void)
Definition: rand.c:10
_CRTIMP void __cdecl _wperror(_In_opt_z_ const wchar_t *_ErrMsg)
__MINGW_EXTENSION _Check_return_ _CRTIMP __int64 __cdecl _wcstoi64(_In_z_ const wchar_t *_Str, _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, _In_ int _Radix)
_CRTIMP int __cdecl ___mb_cur_max_func(void)
Definition: environ.c:438
_Check_return_ __MINGW_EXTENSION unsigned __int64 __cdecl _byteswap_uint64(_In_ unsigned __int64 _Int64)
_Check_return_ _CRTIMP long __cdecl _wtol_l(_In_z_ const wchar_t *_Str, _In_opt_ _locale_t _Locale)
unsigned int uintptr_t
Definition: crtdefs.h:312
int __cdecl mbtowc(_Pre_notnull_ _Post_z_ wchar_t *_DstCh, _In_reads_bytes_opt_(_SrcSizeInBytes) _Pre_opt_z_ const char *_SrcCh, _In_ size_t _SrcSizeInBytes)
__MINGW_EXTENSION _CRTIMP wchar_t *__cdecl _ui64tow(_In_ unsigned __int64 _Val, _Pre_notnull_ _Post_z_ wchar_t *_DstBuf, _In_ int _Radix)
_Check_return_ _CRTIMP char *__cdecl fcvt(_In_ double _Val, _In_ int _NumOfDec, _Out_ int *_PtDec, _Out_ int *_PtSign)
#define __MINGW_EXTENSION
Definition: _mingw.h:166
#define __MINGW_ATTRIB_DEPRECATED
Definition: _mingw.h:132
_CRTIMP char * _sys_errlist[]
Definition: strerror.c:67
_Check_return_ _CRTIMP size_t __cdecl _mbstrlen(_In_z_ const char *_Str)
__CRT_INLINE void __cdecl _Exit(int status)
Definition: stdlib.h:233
_In_ size_t _NewSize
Definition: stdlib.h:710
unsigned char
Definition: typeof.h:29
errno_t __cdecl _set_doserrno(_In_ unsigned long _Value)
#define _In_
Definition: ms_sal.h:308
_CRTIMP errno_t __cdecl _get_wenviron(_Out_ wchar_t ***)
#define _Post_z_
Definition: ms_sal.h:691
__MINGW_EXTENSION long long __cdecl strtoll(const char *__restrict__, char **__restrict, int)
#define _In_z_
Definition: ms_sal.h:313
#define _Inout_updates_bytes_(size)
Definition: ms_sal.h:399
_CRTIMP int __mb_cur_max
Definition: locale.c:37
long quot
Definition: stdlib.h:44
int errno_t
Definition: crtdefs.h:365
_CRTIMP void __cdecl _wsearchenv(_In_z_ const wchar_t *_Filename, _In_z_ const wchar_t *_EnvVar, _Pre_notnull_ _Post_z_ wchar_t *_ResultPath)
_Check_return_ _CRTIMP long __cdecl _atol_l(_In_z_ const char *_Str, _In_opt_ _locale_t _Locale)
void _exit(int exitcode)
Definition: _exit.c:25
_CRTIMP char *__cdecl _ltoa(_In_ long _Value, _Pre_notnull_ _Post_z_ char *_Dest, _In_ int _Radix)
#define _Pre_opt_z_
Definition: ms_sal.h:1274
_Check_return_ unsigned short __cdecl _byteswap_ushort(_In_ unsigned short _Short)
_CRTIMP __MINGW_ATTRIB_DEPRECATED void __cdecl _beep(_In_ unsigned _Frequency, _In_ unsigned _Duration)
_In_ size_t _SizeInWords
Definition: time.h:309
_CRTIMP unsigned int _osver
Definition: environ.c:11
_CRTIMP char *__cdecl _itoa(_In_ int _Value, _Pre_notnull_ _Post_z_ char *_Dest, _In_ int _Radix)
errno_t __cdecl _get_doserrno(_Out_ unsigned long *_Value)
Definition: stdlib.h:81
#define _Deref_post_z_
Definition: ms_sal.h:1121
char * malloc()
__MINGW_EXTENSION char *__cdecl ulltoa(unsigned long long, char *, int)
Definition: stdlib.h:1453
__MINGW_EXTENSION _Check_return_ _CRTIMP __int64 __cdecl _wcstoi64_l(_In_z_ const wchar_t *_Str, _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr, _In_ int _Radix, _In_opt_ _locale_t _Locale)
float f
Definition: stdlib.h:65
_Success_(return >0) _Check_return_ _CRTIMP size_t __cdecl _mbstrnlen(_In_z_ const char *_Str
void *CDECL _aligned_offset_realloc(void *memblock, size_t size, size_t alignment, size_t offset)
Definition: heap.c:424
_CRTIMP char *__cdecl itoa(_In_ int _Val, _Pre_notnull_ _Post_z_ char *_DstBuf, _In_ int _Radix)
_CRTIMP char *__cdecl ltoa(_In_ long _Val, _Pre_notnull_ _Post_z_ char *_DstBuf, _In_ int _Radix)
__MINGW_EXTENSION _Check_return_ _CRTIMP unsigned __int64 __cdecl _strtoui64_l(_In_z_ const char *_String, _Out_opt_ _Deref_post_z_ char **_EndPtr, _In_ int _Radix, _In_opt_ _locale_t _Locale)
_In_ size_t _In_z_ _Printf_format_string_ const char _In_ const struct tm _In_opt_ _locale_t _Locale
Definition: time.h:158
_Check_return_ _CRTIMP int __cdecl _atoflt_l(_Out_ _CRT_FLOAT *_Result, _In_z_ char *_Str, _In_opt_ _locale_t _Locale)
_Check_return_ ldiv_t __cdecl ldiv(_In_ long _Numerator, _In_ long _Denominator)
long long rem
Definition: stdlib.h:1427
_Check_return_ _CRTIMP double __cdecl _wtof_l(_In_z_ const wchar_t *_Str, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP char *__cdecl _fcvt(_In_ double _Val, _In_ int _NumOfDec, _Out_ int *_PtDec, _Out_ int *_PtSign)
_CRTIMP void __cdecl swab(_Inout_updates_z_(_SizeInBytes) char *_Buf1, _Inout_updates_z_(_SizeInBytes) char *_Buf2, _In_ int _SizeInBytes)
_Check_return_ _CRTIMP char *__cdecl ecvt(_In_ double _Val, _In_ int _NumOfDigits, _Out_ int *_PtDec, _Out_ int *_PtSign)
_CRTIMP int __cdecl ___mb_cur_max_l_func(_locale_t)
void *CDECL _aligned_malloc(size_t size, size_t alignment)
Definition: heap.c:415
void *CDECL _aligned_realloc(void *memblock, size_t size, size_t alignment)
Definition: heap.c:539
__MINGW_EXTENSION unsigned long long __cdecl strtoull(const char *__restrict__, char **__restrict__, int)
Definition: strtoull.c:5
__MINGW_EXTENSION __CRT_INLINE long long __cdecl llabs(_In_ long long _j)
Definition: stdlib.h:1435
_Check_return_ _CRTIMP double __cdecl _strtod_l(_In_z_ const char *_Str, _Out_opt_ _Deref_post_z_ char **_EndPtr, _In_opt_ _locale_t _Locale)
_Check_return_ div_t __cdecl div(_In_ int _Numerator, _In_ int _Denominator)
_Check_return_ long __cdecl atol(_In_z_ const char *_Str)
#define _Ret_maybenull_
Definition: ms_sal.h:529
#define _Outptr_result_z_
Definition: ms_sal.h:434
_Check_return_ _CRTIMP double __cdecl _wtof(_In_z_ const wchar_t *_Str)
_CRTIMP void __cdecl _wsplitpath(_In_z_ const wchar_t *_FullPath, _Pre_maybenull_ _Post_z_ wchar_t *_Drive, _Pre_maybenull_ _Post_z_ wchar_t *_Dir, _Pre_maybenull_ _Post_z_ wchar_t *_Filename, _Pre_maybenull_ _Post_z_ wchar_t *_Ext)
Definition: stdlib.h:43
errno_t __cdecl _get_winver(_Out_ unsigned int *_Value)
_CRTIMP __MINGW_ATTRIB_DEPRECATED void __cdecl _seterrormode(_In_ int _Mode)
_CRTIMP __MINGW_ATTRIB_DEPRECATED void __cdecl _sleep(_In_ unsigned long _Duration)
_Check_return_ _Ret_maybenull_ _In_ size_t _SizeOfElements
Definition: stdlib.h:687
#define _Pre_notnull_
Definition: ms_sal.h:680
_CRTIMP size_t __cdecl _mbstowcs_l(_Out_writes_opt_z_(_MaxCount) wchar_t *_Dest, _In_z_ const char *_Source, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale)
long rem
Definition: stdlib.h:45
Definition: stdlib.h:38
_Check_return_ _CRTIMP int __cdecl _wputenv(_In_z_ const wchar_t *_EnvString)
struct _div_t div_t
unsigned int * __p__winver(void)
Definition: environ.c:516
_CRTIMP errno_t __cdecl _get_fmode(_Out_ int *_PMode)
#define _Post_invalid_
Definition: ms_sal.h:695
#define _Pre_maybenull_
Definition: ms_sal.h:681
_Check_return_ _CRTIMP int __cdecl _putenv(_In_z_ const char *_EnvString)
_CRTIMP char ***__cdecl __p__environ()
Definition: environ.c:384
#define abort()
Definition: i386-dis.c:35
_Check_return_ double __cdecl wcstod(_In_z_ const wchar_t *_Str, _Out_opt_ _Deref_post_z_ wchar_t **_EndPtr)
_CRTIMP errno_t __cdecl _get_pgmptr(_Outptr_result_z_ char **_Value)
_CRTIMP int _fmode
Definition: txtmode.c:13
_In_ int _Val
Definition: memory.h:91
void __cdecl free(_Pre_maybenull_ _Post_invalid_ void *_Memory)
_CRTIMP char *__cdecl ultoa(_In_ unsigned long _Val, _Pre_notnull_ _Post_z_ char *_Dstbuf, _In_ int _Radix)
_Check_return_ _CRTIMP int __cdecl _atoldbl(_Out_ _LDOUBLE *_Result, _In_z_ char *_Str)
#define _Check_return_
Definition: ms_sal.h:557
float __cdecl strtof(const char *nptr, char **endptr)
_Check_return_ char *__cdecl getenv(_In_z_ const char *_VarName)
_CRTIMP errno_t __cdecl _get_wpgmptr(_Outptr_result_z_ wchar_t **_Value)
#define _Check_return_opt_
Definition: crtdefs.h:444
long __cdecl labs(_In_ long _X)
_Check_return_ int __cdecl mblen(_In_reads_bytes_opt_(_MaxCount) _Pre_opt_z_ const char *_Ch, _In_ size_t _MaxCount)
_Check_return_opt_ _CRTIMP int __cdecl _set_error_mode(_In_ int _Mode)
_Check_return_ unsigned int __cdecl _rotr(_In_ unsigned int _Val, _In_ int _Shift)
_CRTIMP void __cdecl _searchenv(_In_z_ const char *_Filename, _In_z_ const char *_EnvVar, _Pre_notnull_ _Post_z_ char *_ResultPath)
__MINGW_EXTENSION _CRTIMP char *__cdecl _ui64toa(_In_ unsigned __int64 _Val, _Pre_notnull_ _Post_z_ char *_DstBuf, _In_ int _Radix)
_CRTIMP _purecall_handler __cdecl _set_purecall_handler(_In_opt_ _purecall_handler _Handler)
__MINGW_EXTENSION wchar_t *__cdecl lltow(long long, wchar_t *, int)
Definition: stdlib.h:1455
#define _Out_writes_opt_z_(size)
Definition: ms_sal.h:353
_Check_return_ unsigned long __cdecl _byteswap_ulong(_In_ unsigned long _Long)
int quot
Definition: stdlib.h:39
#define _Inout_updates_z_(size)
Definition: ms_sal.h:389
#define _Out_opt_
Definition: ms_sal.h:346
_CRTIMP int __cdecl _wctomb_l(_Pre_maybenull_ _Post_z_ char *_MbCh, _In_ wchar_t _WCh, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP long __cdecl _wtol(_In_z_ const wchar_t *_Str)
_CRTIMP errno_t __cdecl _get_environ(_Out_ char ***)
__MINGW_EXTENSION __int64 __cdecl _abs64(__int64)
_In_ ULONG _In_ ULONG _Inout_updates_(8 *8) ULONG *pul)
Definition: winddi.h:3522
_Check_return_ unsigned int __cdecl _rotl(_In_ unsigned int _Val, _In_ int _Shift)
_CRTIMP unsigned int __cdecl _set_abort_behavior(_In_ unsigned int _Flags, _In_ unsigned int _Mask)
#define _In_reads_bytes_opt_(size)
Definition: ms_sal.h:322
_Check_return_ int __cdecl atoi(_In_z_ const char *_Str)
_CRTIMP int __argc
Definition: getargs.c:21
__declspec(noreturn) void __cdecl exit(_In_ int _Code)
Definition: thread.c:53
#define calloc
Definition: rosglue.h:14
_CRTIMP wchar_t ** __wargv
Definition: getargs.c:20
_Check_return_ long __cdecl strtol(_In_z_ const char *_Str, _Out_opt_ _Deref_post_z_ char **_EndPtr, _In_ int _Radix)
__MINGW_EXTENSION _Check_return_ _CRTIMP unsigned __int64 __cdecl _strtoui64(_In_z_ const char *_String, _Out_opt_ _Deref_post_z_ char **_EndPtr, _In_ int _Radix)
#define _Post_readable_byte_size_(size)
Definition: ms_sal.h:651
_CRTIMP char *__cdecl _gcvt(_In_ double _Val, _In_ int _NumOfDigits, _Pre_notnull_ _Post_z_ char *_DstBuf)
#define const
Definition: zconf.h:230
__MINGW_EXTENSION _Check_return_ unsigned __int64 __cdecl _rotl64(_In_ unsigned __int64 _Val, _In_ int _Shift)
_Check_return_ _Ret_maybenull_ _In_ size_t _In_ size_t _Offset
Definition: stdlib.h:759
void(__cdecl * _invalid_parameter_handler)(const wchar_t *, const wchar_t *, const wchar_t *, unsigned int, uintptr_t)
Definition: stdlib.h:125
_CRTIMP char * _pgmptr
Definition: environ.c:27
struct _ldiv_t ldiv_t
_In_ size_t _SizeInBytes
Definition: time.h:146
_Check_return_ unsigned long __cdecl strtoul(_In_z_ const char *_Str, _Out_opt_ _Deref_post_z_ char **_EndPtr, _In_ int _Radix)
int rem
Definition: stdlib.h:40
void exit(int exitcode)
Definition: _exit.c:33
_invalid_parameter_handler __cdecl _get_invalid_parameter_handler(void)
Definition: errno.c:151
_CRTIMP char *__cdecl gcvt(_In_ double _Val, _In_ int _NumOfDigits, _Pre_notnull_ _Post_z_ char *_DstBuf)
int _Value
Definition: setjmp.h:188
long double __cdecl strtold(const char *__restrict__, char **__restrict__)
long double x
Definition: stdlib.h:73
_Check_return_ _CRTIMP char *__cdecl _ecvt(_In_ double _Val, _In_ int _NumOfDigits, _Out_ int *_PtDec, _Out_ int *_PtSign)
size_t __cdecl wcstombs(_Out_writes_opt_z_(_MaxCount) char *_Dest, _In_z_ const wchar_t *_Source, _In_ size_t _MaxCount)
_In_ size_t _MaxCount
Definition: stdlib.h:508
_CRTIMP unsigned int _winmajor
Definition: environ.c:13
_Check_return_ _CRTIMP int __cdecl _atodbl(_Out_ _CRT_DOUBLE *_Result, _In_z_ char *_Str)
unsigned int * __p__osver(void)
Definition: environ.c:446
_CRTIMP wchar_t * _wpgmptr
Definition: environ.c:29
__MINGW_EXTENSION char *__cdecl lltoa(long long, char *, int)
Definition: stdlib.h:1452
__MINGW_EXTENSION _Check_return_ _CRTIMP __int64 __cdecl _wtoi64_l(_In_z_ const wchar_t *_Str, _In_opt_ _locale_t _Locale)
__MINGW_EXTENSION _Check_return_ _CRTIMP __int64 __cdecl _strtoi64_l(_In_z_ const char *_String, _Out_opt_ _Deref_post_z_ char **_EndPtr, _In_ int _Radix, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP int __cdecl _atodbl_l(_Out_ _CRT_DOUBLE *_Result, _In_z_ char *_Str, _In_opt_ _locale_t _Locale)
#define MB_LEN_MAX
Definition: limits.h:35
_Check_return_ _CRTIMP int __cdecl _wtoi_l(_In_z_ const wchar_t *_Str, _In_opt_ _locale_t _Locale)
_Check_return_ _CRTIMP wchar_t *__cdecl _wgetenv(_In_z_ const wchar_t *_VarName)
#define __int64
Definition: basetyps.h:16
_CRTIMP wchar_t **__cdecl __p__wpgmptr()
Definition: environ.c:477
unsigned int(__cdecl typeof(jpeg_read_scanlines))(struct jpeg_decompress_struct *
Definition: typeof.h:31
_Check_return_ unsigned long __cdecl _lrotr(_In_ unsigned long _Val, _In_ int _Shift)
#define _In_reads_bytes_(size)
Definition: ms_sal.h:321
onexit_t __cdecl onexit(_In_opt_ onexit_t _Func)
__MINGW_EXTENSION wchar_t *__cdecl ulltow(unsigned long long, wchar_t *, int)
Definition: stdlib.h:1456
Definition: ps.c:97
_Check_return_ _CRTIMP size_t __cdecl _mbstrnlen_l(_In_z_ const char *_Str, _In_ size_t _MaxCount, _In_opt_ _locale_t _Locale)