summaryrefslogtreecommitdiffhomepage
path: root/ir/be/beutil.c
diff options
context:
space:
mode:
authorChristoph Mallon <christoph.mallon@gmx.de>2008-09-11 14:13:58 +0200
committerChristoph Mallon <christoph.mallon@gmx.de>2008-09-11 14:13:58 +0200
commit7028fcf7d7e9b79261634b3f103a226e9e903a0d (patch)
tree4049d9d66789fb329beac037d22781bd728d0006 /ir/be/beutil.c
parentf4e5f09589f68012dbd8007389366dd992f7a7c5 (diff)
In be_get_Proj_for_pn() before getting the proj number make sure that the node really is a Proj (could be End due to keep alive).
[r21847]
Diffstat (limited to 'ir/be/beutil.c')
-rw-r--r--ir/be/beutil.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ir/be/beutil.c b/ir/be/beutil.c
index 3739603..8754f4d 100644
--- a/ir/be/beutil.c
+++ b/ir/be/beutil.c
@@ -230,7 +230,7 @@ ir_node *be_get_Proj_for_pn(const ir_node *irn, long pn) {
foreach_out_edge(irn, edge) {
proj = get_edge_src_irn(edge);
- if (get_Proj_proj(proj) == pn)
+ if (is_Proj(proj) && get_Proj_proj(proj) == pn)
return proj;
}