summaryrefslogtreecommitdiff
path: root/ext/syck/node.c
diff options
context:
space:
mode:
authormame <mame@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-09-11 16:37:41 +0000
committermame <mame@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-09-11 16:37:41 +0000
commit3f1a95ce65391170458b4d6015b1455e154b706d (patch)
tree955b97db2f7036c07b689a9edd135b672f0608a9 /ext/syck/node.c
parent73412af59a8327923ed0f7ae91efbb6c4f0c0b80 (diff)
* ext/syck/node.c (syck_replace_str2): fix wrong check to free ptr.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19297 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/syck/node.c')
-rw-r--r--ext/syck/node.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/syck/node.c b/ext/syck/node.c
index 890eba9d58..fb98f655cc 100644
--- a/ext/syck/node.c
+++ b/ext/syck/node.c
@@ -128,7 +128,7 @@ syck_replace_str( SyckNode *n, char *str, enum scalar_style style )
void
syck_replace_str2( SyckNode *n, char *str, long len, enum scalar_style style )
{
- if ( n->data.str != NULL )
+ if ( n->data.str->ptr != NULL )
{
S_FREE( n->data.str->ptr );
n->data.str->ptr = NULL;