From bf2f90a0028f35ef79d204c6fc997a96cafa371a Mon Sep 17 00:00:00 2001 From: Logan Chien Date: Thu, 25 Jun 2015 00:05:24 +0000 Subject: Avoid C99 for-declaration statement in C files. (NFC) To compile libunwind with gcc/g++ 4.9, it is required to avoid the for-declaration statement from C99. git-svn-id: https://llvm.org/svn/llvm-project/libunwind/trunk@240609 91177308-0d34-0410-b5e6-96231b3b80d8 --- src/UnwindLevel1.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/UnwindLevel1.c b/src/UnwindLevel1.c index 84627c2..61abd89 100644 --- a/src/UnwindLevel1.c +++ b/src/UnwindLevel1.c @@ -31,8 +31,8 @@ unwind_phase1(unw_context_t *uc, _Unwind_Exception *exception_object) { unw_init_local(&cursor1, uc); // Walk each frame looking for a place to stop. - for (bool handlerNotFound = true; handlerNotFound;) { - + bool handlerNotFound = true; + while (handlerNotFound) { // Ask libuwind to get next frame (skip over first which is // _Unwind_RaiseException). int stepResult = unw_step(&cursor1); -- cgit v1.2.3