From c20c8c79e78424243403e3f72520625530aa4074 Mon Sep 17 00:00:00 2001 From: Dodji Seketeli Date: Sun, 4 Oct 2015 11:30:57 +0200 Subject: [PATCH] Fix infinite loop in peel_typedef_pointer_or_reference_type * src/abg-ir.cc (peel_typedef_pointer_or_reference_type): Make sure the variable tested in the condition is the one updated by the loop. Signed-off-by: Dodji Seketeli --- src/abg-ir.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/abg-ir.cc b/src/abg-ir.cc index 832cc588..9b30959f 100644 --- a/src/abg-ir.cc +++ b/src/abg-ir.cc @@ -3286,7 +3286,7 @@ type_base_sptr peel_typedef_pointer_or_reference_type(const type_base_sptr type) { type_base_sptr typ = type; - while (is_typedef(type) || is_pointer_type(type) || is_reference_type(type)) + while (is_typedef(typ) || is_pointer_type(typ) || is_reference_type(typ)) { if (typedef_decl_sptr t = is_typedef(typ)) typ = peel_typedef_type(t); -- 2.43.5