summaryrefslogtreecommitdiff
path: root/src/cairoint.h
diff options
context:
space:
mode:
authorAdrian Johnson <ajohnson@redneon.com>2023-01-03 15:05:51 +1030
committerAdrian Johnson <ajohnson@redneon.com>2023-01-03 15:27:03 +1030
commit5e0e40e3c53d253bb767606f847182f95a443547 (patch)
tree4bb35e92e817feadc44b98874b0bb0cf5b68e074 /src/cairoint.h
parent1af1e11254c29f6bd1f61b9e1776a57d4a772919 (diff)
downloadcairo-5e0e40e3c53d253bb767606f847182f95a443547.tar.gz
Fix mingw build failure when SVG fonts enabled
Add missing strndup() function. Copied the strndup() implementation from util/cairo-missing/strndup.c plus a bug fix.
Diffstat (limited to 'src/cairoint.h')
-rw-r--r--src/cairoint.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/cairoint.h b/src/cairoint.h
index af0f0fadc..976162e6f 100644
--- a/src/cairoint.h
+++ b/src/cairoint.h
@@ -943,6 +943,13 @@ _cairo_get_locale_decimal_point (void);
cairo_private double
_cairo_strtod (const char *nptr, char **endptr);
+#ifdef HAVE_STRNDUP
+#define _cairo_strndup strndup
+#else
+cairo_private char *
+_cairo_strndup (const char *s, size_t n);
+#endif
+
/* cairo-path-fixed.c */
cairo_private cairo_path_fixed_t *
_cairo_path_fixed_create (void);