[memprof: 8/76] stack-frame.c: Initialize count, gcc is not smart enough to read the if..



commit 9bb33df7b8b1bd2d1949088535b2f4c787727865
Author: Holger Hans Peter Freyther <zecke selfish org>
Date:   Thu Jun 4 12:59:06 2009 +0200

    stack-frame.c: Initialize count, gcc is not smart enough to read the if..

 lib/stack-frame.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/lib/stack-frame.c b/lib/stack-frame.c
index 7dd0b10..ebb2c92 100644
--- a/lib/stack-frame.c
+++ b/lib/stack-frame.c
@@ -45,7 +45,7 @@
 void
 mi_call_with_backtrace (int to_skip, void callback (int, void **, void *), void *data)
 {
-    int bufsiz = 128, count;
+    int bufsiz = 128, count = 0;
     void **buf;
 	static __thread int in_backtrace = 0;
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]