From 0e6b4b2400baba8b4439c902fff94d37adae6210 Mon Sep 17 00:00:00 2001 From: wollman Date: Thu, 30 May 2002 21:18:01 +0000 Subject: Fix preprocessor directive syntax (text after #endif). The style of this program is still atrocious (not fixed). --- usr.bin/gprof/lookup.c | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) (limited to 'usr.bin/gprof/lookup.c') diff --git a/usr.bin/gprof/lookup.c b/usr.bin/gprof/lookup.c index c276346..9badc6c 100644 --- a/usr.bin/gprof/lookup.c +++ b/usr.bin/gprof/lookup.c @@ -32,7 +32,11 @@ */ #ifndef lint +#if 0 static char sccsid[] = "@(#)lookup.c 8.1 (Berkeley) 6/6/93"; +#endif +static const char rcsid[] = + "$FreeBSD$"; #endif /* not lint */ #include "gprof.h" @@ -53,18 +57,18 @@ nllookup( address ) register int probes; probes = 0; -# endif DEBUG +# endif /* DEBUG */ for ( low = 0 , high = nname - 1 ; low != high ; ) { # ifdef DEBUG probes += 1; -# endif DEBUG +# endif /* DEBUG */ middle = ( high + low ) >> 1; if ( nl[ middle ].value <= address && nl[ middle+1 ].value > address ) { # ifdef DEBUG if ( debug & LOOKUPDEBUG ) { printf( "[nllookup] %d (%d) probes\n" , probes , nname-1 ); } -# endif DEBUG +# endif /* DEBUG */ return &nl[ middle ]; } if ( nl[ middle ].value > address ) { @@ -78,7 +82,7 @@ nllookup( address ) fprintf( stderr , "[nllookup] (%d) binary search fails\n" , nname-1 ); } -# endif DEBUG +# endif /* DEBUG */ return 0; } @@ -98,7 +102,7 @@ arclookup( parentp , childp ) printf( "[arclookup] parent %s child %s\n" , parentp -> name , childp -> name ); } -# endif DEBUG +# endif /* DEBUG */ for ( arcp = parentp -> children ; arcp ; arcp = arcp -> arc_childlist ) { # ifdef DEBUG if ( debug & LOOKUPDEBUG ) { @@ -106,7 +110,7 @@ arclookup( parentp , childp ) arcp -> arc_parentp -> name , arcp -> arc_childp -> name ); } -# endif DEBUG +# endif /* DEBUG */ if ( arcp -> arc_childp == childp ) { return arcp; } -- cgit v1.1