From 37ac4b3fbf36ddaf104df9022fa633784c3fc491 Mon Sep 17 00:00:00 2001 From: Erick Turnquist Date: Thu, 1 Jan 2009 00:15:15 +0000 Subject: [PATCH] (trunk libT) fix endian oops in tr_suspectAddress() --- libtransmission/net.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libtransmission/net.c b/libtransmission/net.c index d16fe2a26..1d292636f 100644 --- a/libtransmission/net.c +++ b/libtransmission/net.c @@ -72,7 +72,7 @@ void tr_suspectAddress( const tr_address * a, const char * source ) { /* be really aggressive in what we report */ - if( a->type == TR_AF_INET && !( a->addr.addr4.s_addr & 0xff000000 ) ) + if( a->type == TR_AF_INET && !( ntohl( a->addr.addr4.s_addr ) & 0xff000000 ) ) tr_err( "Funny looking address %s from %s", tr_ntop_non_ts( a ), source ); /* /16s taken from ipv6 rib on 21 dec, 2008 */ /* this is really, really ugly. expedience over quality */ -- 2.40.0