projects
/
binutils-gdb.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a03db86
)
* eval.c (evaluate_subexp_standard): Assert that there is at
author
Daniel Jacobowitz
<drow@false.org>
Tue, 4 Nov 2008 15:32:54 +0000
(15:32 +0000)
committer
Daniel Jacobowitz
<drow@false.org>
Tue, 4 Nov 2008 15:32:54 +0000
(15:32 +0000)
least one array dimension.
gdb/ChangeLog
patch
|
blob
|
history
gdb/eval.c
patch
|
blob
|
history
diff --git
a/gdb/ChangeLog
b/gdb/ChangeLog
index 1c7b03cef2ae2ede6a9bb86d2182aaa1967b7303..45bbb122ecc8f7f8c5ae5dfbe29d09b6f91ebec3 100644
(file)
--- a/
gdb/ChangeLog
+++ b/
gdb/ChangeLog
@@
-1,3
+1,8
@@
+2008-11-04 Daniel Jacobowitz <dan@codesourcery.com>
+
+ * eval.c (evaluate_subexp_standard): Assert that there is at
+ least one array dimension.
+
2008-11-03 Vladimir Prus <vladimir@codesourcery.com>
Make attach_command exception-safe
diff --git
a/gdb/eval.c
b/gdb/eval.c
index 4394aa19bd4ecd55aff3cc1b079d48cc12029288..ccb6b742b618b6a04f8840be23a34b7fc5cf4be4 100644
(file)
--- a/
gdb/eval.c
+++ b/
gdb/eval.c
@@
-1976,6
+1976,8
@@
evaluate_subexp_standard (struct type *expect_type,
if (nargs != ndimensions)
error (_("Wrong number of subscripts"));
+ gdb_assert (nargs > 0);
+
/* Now that we know we have a legal array subscript expression
let us actually find out where this element exists in the array. */