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