зеркало из https://github.com/github/ruby.git
* ext/syck/rubyext.c (rb_syck_compile): remove meaningless branch
that misleads into thinking that the variable sav may be uninitialized. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18282 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
ea79b2360a
Коммит
368d944621
|
@ -1,3 +1,9 @@
|
|||
Thu Jul 31 02:21:39 2008 Yusuke Endoh <mame@tsg.ne.jp>
|
||||
|
||||
* ext/syck/rubyext.c (rb_syck_compile): remove meaningless branch
|
||||
that misleads into thinking that the variable sav may be
|
||||
uninitialized.
|
||||
|
||||
Thu Jul 31 01:25:43 2008 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||
|
||||
* thread.c (rb_mutex_unlock_all): mutex is no longer a ruby object.
|
||||
|
|
|
@ -104,7 +104,7 @@ rb_syck_compile(VALUE self, VALUE port)
|
|||
char *ret;
|
||||
VALUE bc;
|
||||
bytestring_t *sav = NULL;
|
||||
void *data;
|
||||
void *data = NULL;
|
||||
|
||||
SyckParser *parser = syck_new_parser();
|
||||
taint = syck_parser_assign_io(parser, &port);
|
||||
|
@ -113,7 +113,8 @@ rb_syck_compile(VALUE self, VALUE port)
|
|||
syck_parser_implicit_typing( parser, 0 );
|
||||
syck_parser_taguri_expansion( parser, 0 );
|
||||
oid = syck_parse( parser );
|
||||
if (syck_lookup_sym( parser, oid, &data )) sav = data;
|
||||
ASSERT(syck_lookup_sym( parser, oid, &data ));
|
||||
sav = data;
|
||||
|
||||
ret = S_ALLOCA_N( char, strlen( sav->buffer ) + 3 );
|
||||
ret[0] = '\0';
|
||||
|
|
Загрузка…
Ссылка в новой задаче