From 46c777ac1468aa406478ce00bf6acdc430218d6d Mon Sep 17 00:00:00 2001 From: matz Date: Thu, 7 Oct 2004 04:06:41 +0000 Subject: * pack.c (pack_unpack): string conversion should at the top of the method. [ruby-dev:24439] * io.c (io_read): buffer should be frozen only after the length check. [ruby-dev:24440] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@7010 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- pack.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'pack.c') diff --git a/pack.c b/pack.c index baff504bea..a435e130b2 100644 --- a/pack.c +++ b/pack.c @@ -1377,9 +1377,9 @@ pack_unpack(str, fmt) #endif StringValue(str); + StringValue(fmt); s = RSTRING(str)->ptr; send = s + RSTRING(str)->len; - StringValue(fmt); p = RSTRING(fmt)->ptr; pend = p + RSTRING(fmt)->len; -- cgit v1.2.3