-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathstring_stubs.h
More file actions
54 lines (43 loc) · 1.21 KB
/
string_stubs.h
File metadata and controls
54 lines (43 loc) · 1.21 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
#ifndef USE_HEADERS
#ifndef HEADER_STRINGSTUB_STUB_H
#define HEADER_STRINGSTUB_STUB_H
#ifdef __cplusplus
extern "C" {
#endif
#ifndef NULL
#define NULL 0
#endif
typedef int wchar_t;
extern void *memcpy(void *dst, const void *src, unsigned long n);
extern char* strcpy_s(char* dst, int max_amount, char* src);
extern int _mbsncat(char* dst, char* src, int count);
extern int _mbsncmp(char* dst, char* src, int count);
extern int _memicmp(char* a, char* b, long count);
extern int _mbsnbcmp(char* a, char* b, int count);
extern int printf(const char * format, ...);
extern unsigned long strlen(const char *s);
extern char* strcpy(char * dst, const char * src);
extern int wprintf(const wchar_t * format, ...);
extern wchar_t* wcscpy(wchar_t * s1, const wchar_t * s2);
extern void perror(const char *s);
extern void openlog(const char*, int, int);
extern void syslog(int, const char*, ...);
extern void closelog(void);
#ifdef __cplusplus
}
#endif
#endif
#else
#include <strings.h>
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <wchar.h>
#include <syslog.h>
#define strcpy_s strcpy
#define _mbsncat strncat
#define _mbsncmp memcmp
#define _memicmp memcmp
#define _mbsnbcmp memcmp
#define mempcpy memcpy
#endif