Backport #9493

parameters equals to 0 (== lowerbound) should not accept.

Added by Koichi Sasada 2 months ago. Updated 2 months ago.

[ruby-dev:47963]
Status:Closed
Priority:Normal
Assignee:-

Description

Please backport r44861, r44862.

さっきバックポートしてもらったものに、FOO=0 として、
0 を受け取れるようにしてみたんですが、
FOO=(空)や FOO=xxx のように数値以外が入ってきても 0 になっちゃって、
誤入力が増えるので、0 を指定するべきではないと思い修正しました。

あと、r44862 は警告メッセージが間違っていたので修正です。

Associated revisions

Revision 44868
Added by Yui NARUSE 2 months ago

merge revision(s) 44861,44862: [Backport #9493]

* gc.c (get_envparam_int): don't accept a value equals to lowerbound
  (changed by last commit) because "" or "foo" (not a number) strings
  are parsed as 0. They should be rejected.

* gc.c (get_envparam_double): ditto.

* gc.c (get_envparam_int): accept a value equals to lowerbound.

* gc.c (get_envparam_int): correct warning messsages.

* gc.c (get_envparam_double): ditto.

History

#1 Updated by Yui NARUSE 2 months ago

  • Status changed from Open to Closed
  • % Done changed from 0 to 100

Applied in changeset r44868.


merge revision(s) 44861,44862: [Backport #9493]

* gc.c (get_envparam_int): don't accept a value equals to lowerbound
  (changed by last commit) because "" or "foo" (not a number) strings
  are parsed as 0. They should be rejected.

* gc.c (get_envparam_double): ditto.

* gc.c (get_envparam_int): accept a value equals to lowerbound.

* gc.c (get_envparam_int): correct warning messsages.

* gc.c (get_envparam_double): ditto.

Also available in: Atom PDF