From: anthony Date: Wed, 12 May 2010 02:27:05 +0000 (+0000) Subject: Warning to NOT free the string returned X-Git-Tag: 7.0.1-0~9484 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=580609e43fd04b71f5564268cf313c42b686db5e;p=imagemagick Warning to NOT free the string returned for GetImageArtifact() and GetValueFromSplayTree() --- 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)