Fix a memory leak found by Hui Zhu <teawater@gmail.com>.
authorJan Kratochvil <jan.kratochvil@redhat.com>
Wed, 25 Jun 2008 15:49:20 +0000 (15:49 +0000)
committerJan Kratochvil <jan.kratochvil@redhat.com>
Wed, 25 Jun 2008 15:49:20 +0000 (15:49 +0000)
commitfe9441f601347a780ae356cd935aef2d37b824ee
tree60b5ba44d88c627c679fee814c9860e15ec76646
parent2c40eaebf8d01330b1ee59a262d651fbd5192f32
Fix a memory leak found by Hui Zhu <teawater@gmail.com>.
* c-exp.y (parse_number): Move the S and SAVED_CHAR initialization
after the DECFLOAT detection to fix a memory leak.  Remove the
redundant NUM initialization.  Protect the DECFLOAT detection memory
access before the P block.  Restore the P memory content for the
DECFLOAT detection.
gdb/ChangeLog
gdb/c-exp.y