aboutsummaryrefslogtreecommitdiff
path: root/gdb/cp-abi.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/cp-abi.c')
-rw-r--r--gdb/cp-abi.c18
1 files changed, 10 insertions, 8 deletions
diff --git a/gdb/cp-abi.c b/gdb/cp-abi.c
index 9316c4c..70a0528 100644
--- a/gdb/cp-abi.c
+++ b/gdb/cp-abi.c
@@ -80,15 +80,17 @@ baseclass_offset (struct type *type, int index, const gdb_byte *valaddr,
embedded_offset,
address, val);
}
+ if (ex.reason < 0)
+ {
+ if (ex.error != NOT_AVAILABLE_ERROR)
+ throw_exception (ex);
+
+ throw_error (NOT_AVAILABLE_ERROR,
+ _("Cannot determine virtual baseclass offset "
+ "of incomplete object"));
+ }
- if (ex.reason < 0 && ex.error == NOT_AVAILABLE_ERROR)
- throw_error (NOT_AVAILABLE_ERROR,
- _("Cannot determine virtual baseclass offset "
- "of incomplete object"));
- else if (ex.reason < 0)
- throw_exception (ex);
- else
- return res;
+ return res;
}
struct value *