From dd8f7a6cfdce76078c1deb3d39e6f95edc1283c1 Mon Sep 17 00:00:00 2001 From: glass Date: Sun, 28 Jul 2013 08:49:25 +0000 Subject: * string.c: add internal API rb_str_locktmp_ensure(). * io.c (io_fread): use rb_str_locktmp_ensure(). [ruby-core:56121] [Bug #8669] * test/ruby/test_io.rb: add a test for above. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@42212 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- internal.h | 1 + 1 file changed, 1 insertion(+) (limited to 'internal.h') diff --git a/internal.h b/internal.h index b7a8a75669..46d64b00fc 100644 --- a/internal.h +++ b/internal.h @@ -419,6 +419,7 @@ VALUE rb_id_quote_unprintable(ID); #define QUOTE(str) rb_str_quote_unprintable(str) #define QUOTE_ID(id) rb_id_quote_unprintable(id) void rb_str_fill_terminator(VALUE str, const int termlen); +VALUE rb_str_locktmp_ensure(VALUE str, VALUE (*func)(VALUE), VALUE arg); /* struct.c */ VALUE rb_struct_init_copy(VALUE copy, VALUE s); -- cgit v1.2.3