expr.c (interpret_float_suffix): Add a guard.

2012-05-10  Tristan Gingold  <gingold@adacore.com>

	* expr.c (interpret_float_suffix): Add a guard.

From-SVN: r187364
This commit is contained in:
Tristan Gingold 2012-05-10 08:04:18 +00:00 committed by Tristan Gingold
parent 3ac8781c36
commit 638d20652b
2 changed files with 11 additions and 6 deletions

View File

@ -1,3 +1,7 @@
2012-05-10 Tristan Gingold <gingold@adacore.com>
* expr.c (interpret_float_suffix): Add a guard.
2012-05-02 Dodji Seketeli <dodji@redhat.com> 2012-05-02 Dodji Seketeli <dodji@redhat.com>
Properly initialize cpp_context in destringize_and_run Properly initialize cpp_context in destringize_and_run

View File

@ -110,6 +110,7 @@ interpret_float_suffix (const uchar *s, size_t len)
} }
/* Recognize a fixed-point suffix. */ /* Recognize a fixed-point suffix. */
if (len != 0)
switch (s[len-1]) switch (s[len-1])
{ {
case 'k': case 'K': flags = CPP_N_ACCUM; break; case 'k': case 'K': flags = CPP_N_ACCUM; break;