зеркало из https://github.com/github/ruby.git
* error.c (rb_bug_reporter_add): return simply 0 if failed.
Please check return value. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43312 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
7726089eaa
Коммит
f9718bf703
|
@ -1,3 +1,8 @@
|
|||
Thu Oct 17 05:31:31 2013 Koichi Sasada <ko1@atdot.net>
|
||||
|
||||
* error.c (rb_bug_reporter_add): return simply 0 if failed.
|
||||
Please check return value.
|
||||
|
||||
Thu Oct 17 05:17:33 2013 Koichi Sasada <ko1@atdot.net>
|
||||
|
||||
* ext/objspace/object_tracing.c: add new method
|
||||
|
|
4
error.c
4
error.c
|
@ -278,13 +278,13 @@ rb_bug_reporter_add(void (*func)(FILE *, void *), void *data)
|
|||
{
|
||||
struct bug_reporters *reporter;
|
||||
if (bug_reporters_size >= MAX_BUG_REPORTERS) {
|
||||
rb_bug("rb_bug_reporter_add: overflow");
|
||||
return 0; /* failed to register */
|
||||
}
|
||||
reporter = &bug_reporters[bug_reporters_size++];
|
||||
reporter->func = func;
|
||||
reporter->data = data;
|
||||
|
||||
return bug_reporters_size;
|
||||
return 1;
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
Загрузка…
Ссылка в новой задаче