From 5f5007883e17b6f030d34b2b7d813426df73505a Mon Sep 17 00:00:00 2001 From: erdgeist <> Date: Sun, 7 Dec 2008 12:04:43 +0000 Subject: [PATCH] Fix post increase on wrong pointer type. --- ot_fullscrape.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ot_fullscrape.c b/ot_fullscrape.c index 9a6effb..523d883 100644 --- a/ot_fullscrape.c +++ b/ot_fullscrape.c @@ -177,8 +177,8 @@ static void fullscrape_make( int *iovec_entries, struct iovec **iovector, ot_tas break; case TASK_FULLSCRAPE_TPB_BINARY: for(i=0;i<20;i+=4) WRITE32(r+=4,0,READ32(hash,i)); - *(uint32_t*)r++ = htonl( (uint32_t)peer_list->seed_count ); - *(uint32_t*)r++ = htonl( (uint32_t)( peer_list->peer_count-peer_list->seed_count) ); + *(uint32_t*)(r+=4) = htonl( (uint32_t) peer_list->seed_count ); + *(uint32_t*)(r+=4) = htonl( (uint32_t)( peer_list->peer_count-peer_list->seed_count) ); break; case TASK_FULLSCRAPE_TPB_URLENCODED: r += fmt_urlencoded( r, (char *)*hash, 20 );