From 580609e43fd04b71f5564268cf313c42b686db5e Mon Sep 17 00:00:00 2001 From: anthony Date: Wed, 12 May 2010 02:27:05 +0000 Subject: [PATCH] Warning to NOT free the string returned for GetImageArtifact() and GetValueFromSplayTree() --- magick/artifact.c | 3 +++ magick/splay-tree.c | 3 +++ 2 files changed, 6 insertions(+) diff --git a/magick/artifact.c b/magick/artifact.c index e686f4ee6..ca4cb786b 100644 --- a/magick/artifact.c +++ b/magick/artifact.c @@ -248,6 +248,9 @@ MagickExport void DestroyImageArtifacts(Image *image) % % GetImageArtifact() gets a value associated with an image artifact. % +% WARNING: The pointer returned points directly to stored values. +% Do not free the memory they pointed to. +% % The format of the GetImageArtifact method is: % % const char *GetImageArtifact(const Image *image,const char *key) diff --git a/magick/splay-tree.c b/magick/splay-tree.c index 3b22b8ccf..cdac5eb4d 100644 --- a/magick/splay-tree.c +++ b/magick/splay-tree.c @@ -857,6 +857,9 @@ MagickExport void *GetNextValueInSplayTree(SplayTreeInfo *splay_tree) % % GetValueFromSplayTree() gets a value from the splay-tree by its key. % +% WARNING: The pointer returned points directly into the values stored in +% tree. Do not free the memory pointed to. +% % The format of the GetValueFromSplayTree method is: % % void *GetValueFromSplayTree(SplayTreeInfo *splay_tree,const void *key) -- 2.50.1