[vala] Fix crash when using invalid conditional expressions
- From: Jürg Billeter <juergbi src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [vala] Fix crash when using invalid conditional expressions
- Date: Mon, 14 Sep 2009 16:16:43 +0000 (UTC)
commit fc3150d0d356286917d57d7f057240c5a392d3bb
Author: Jürg Billeter <j bitron ch>
Date: Mon Sep 14 18:14:39 2009 +0200
Fix crash when using invalid conditional expressions
Fixes bug 594400.
vala/valaconditionalexpression.vala | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/vala/valaconditionalexpression.vala b/vala/valaconditionalexpression.vala
index f521bc8..6c7e8d6 100644
--- a/vala/valaconditionalexpression.vala
+++ b/vala/valaconditionalexpression.vala
@@ -137,7 +137,8 @@ public class Vala.ConditionalExpression : Expression {
insert_statement (analyzer.insert_block, decl);
insert_statement (analyzer.insert_block, if_stmt);
- if (!if_stmt.check (analyzer)) {
+ if (!if_stmt.check (analyzer) || true_expression.error || false_expression.error) {
+ error = true;
return false;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]