From 37bae3bf7534cfdfc9fcafe8324c9ed4760746a2 Mon Sep 17 00:00:00 2001 From: Charles Kerr Date: Tue, 6 May 2008 16:32:45 +0000 Subject: [PATCH] fix cli compile issue reported & patched by mdomsch --- cli/transmissioncli.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/cli/transmissioncli.c b/cli/transmissioncli.c index d7bce69f0..89b636a71 100644 --- a/cli/transmissioncli.c +++ b/cli/transmissioncli.c @@ -243,15 +243,14 @@ main( int argc, char ** argv ) if( showScrape ) { + const struct tr_stat * stats; + const uint64_t start = tr_date( ); printf( "Scraping, Please wait...\n" ); - const tr_stat * stats; - - uint64_t start = tr_date(); do { stats = tr_torrentStat( tor ); - if( stats == NULL || tr_date() - start > 20000 ) + if( !stats || tr_date() - start > 20000 ) { printf( "Scrape failed.\n" ); goto cleanup; @@ -276,7 +275,7 @@ main( int argc, char ** argv ) { char string[LINEWIDTH]; int chars = 0; - const tr_stat * s; + const struct tr_stat * s; tr_wait( 1000 ); -- 2.40.0