diff options
Diffstat (limited to 'src/utils.h')
-rw-r--r-- | src/utils.h | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/src/utils.h b/src/utils.h new file mode 100644 index 0000000..98a4c6b --- /dev/null +++ b/src/utils.h @@ -0,0 +1,21 @@ +/* utility helpers + * + * This file is part of nsnsgenbind. + * Licensed under the MIT License, + * http://www.opensource.org/licenses/mit-license.php + * Copyright 2015 Vincent Sanders <vince@netsurf-browser.org> + */ + +#ifndef nsgenbind_utils_h +#define nsgenbind_utils_h + +FILE *genb_fopen(const char *fname, const char *mode); + +#ifdef _WIN32 +#define NEED_STRNDUP 1 +char *strndup(const char *s, size_t n); +#endif + +#define SLEN(x) (sizeof((x)) - 1) + +#endif |