diff options
Diffstat (limited to 'src/util/private.c')
-rw-r--r-- | src/util/private.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/util/private.c b/src/util/private.c index 92075c2..47c2699 100644 --- a/src/util/private.c +++ b/src/util/private.c @@ -32,6 +32,7 @@ in this Software without prior written authorization from The Open Group. #include <config.h> #endif #include "libxfontint.h" +#include "src/util/replace.h" #include <X11/fonts/fontmisc.h> #include <X11/fonts/fontstruct.h> @@ -84,7 +85,7 @@ xfont2_font_set_private(FontPtr pFont, int n, pointer ptr) if (n > pFont->maxPrivate) { if (pFont->devPrivates && pFont->devPrivates != (pointer)(&pFont[1])) { - new = realloc (pFont->devPrivates, (n + 1) * sizeof (pointer)); + new = reallocarray (pFont->devPrivates, (n + 1), sizeof (pointer)); if (!new) return FALSE; } else { |