* util.c (ruby_dtoa): allocates one more byte to get rid of buffer
overrun. a patch from Charlie Savage at [ruby-core:22604]. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@22692 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
a6c52eec0c
commit
cbeec45612
@ -1,3 +1,8 @@
|
|||||||
|
Sun Mar 1 19:36:18 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
|
* util.c (ruby_dtoa): allocates one more byte to get rid of buffer
|
||||||
|
overrun. a patch from Charlie Savage at [ruby-core:22604].
|
||||||
|
|
||||||
Sun Mar 1 19:10:59 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
Sun Mar 1 19:10:59 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||||
|
|
||||||
* common.mk (.y.c): removed extra backslash. [ruby-core:22602]
|
* common.mk (.y.c): removed extra backslash. [ruby-core:22602]
|
||||||
|
2
util.c
2
util.c
@ -3362,7 +3362,7 @@ ruby_dtoa(double d_, int mode, int ndigits, int *decpt, int *sign, char **rve)
|
|||||||
if (i <= 0)
|
if (i <= 0)
|
||||||
i = 1;
|
i = 1;
|
||||||
}
|
}
|
||||||
s = s0 = rv_alloc(i);
|
s = s0 = rv_alloc(i+1);
|
||||||
|
|
||||||
#ifdef Honor_FLT_ROUNDS
|
#ifdef Honor_FLT_ROUNDS
|
||||||
if (mode > 1 && rounding != 1)
|
if (mode > 1 && rounding != 1)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user