From 270c31e8a938c38237d554c34c5e2b4d16a6941b Mon Sep 17 00:00:00 2001 From: Cristy Date: Sat, 30 Sep 2017 10:20:09 -0400 Subject: [PATCH] https://github.com/ImageMagick/ImageMagick/issues/801 --- MagickCore/xwindow.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/MagickCore/xwindow.c b/MagickCore/xwindow.c index f85e9de11..92b88c4ce 100644 --- a/MagickCore/xwindow.c +++ b/MagickCore/xwindow.c @@ -63,6 +63,7 @@ #include "MagickCore/log.h" #include "MagickCore/magick.h" #include "MagickCore/memory_.h" +#include "MagickCore/memory-private.h" #include "MagickCore/monitor.h" #include "MagickCore/nt-base-private.h" #include "MagickCore/option.h" @@ -4622,7 +4623,7 @@ MagickPrivate void XGetWindowInfo(Display *display,XVisualInfo *visual_info, *segment_info; if (window->segment_info == (void *) NULL) - window->segment_info=AcquireQuantumMemory(2,sizeof(*segment_info)); + window->segment_info=AcquireCriticalMemory(2*sizeof(*segment_info)); segment_info=(XShmSegmentInfo *) window->segment_info; segment_info[0].shmid=(-1); segment_info[0].shmaddr=(char *) NULL; -- 2.40.0