From 00e5db6a9cd19c396f8cd50840559759060cfbdd Mon Sep 17 00:00:00 2001 From: Dan Bechard Date: Fri, 4 Oct 2024 17:18:53 -0400 Subject: [PATCH] Loop variable consistency Signed-off-by: Dan Bechard --- test.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/test.cpp b/test.cpp index 2902279c..ea097577 100644 --- a/test.cpp +++ b/test.cpp @@ -1100,15 +1100,15 @@ void test_connection_unreliable_unordered_blocks() const int NumMessagesSent = 8; - for ( int j = 0; j < NumMessagesSent; ++j ) + for ( int i = 0; i < NumMessagesSent; ++i ) { TestBlockMessage * message = (TestBlockMessage*) messageFactory.CreateMessage( TEST_BLOCK_MESSAGE ); check( message ); - message->sequence = j; - const int blockSize = 1 + ( j * 7 ); + message->sequence = i; + const int blockSize = 1 + ( i * 7 ); uint8_t * blockData = (uint8_t*) YOJIMBO_ALLOCATE( messageFactory.GetAllocator(), blockSize ); - for ( int k = 0; k < blockSize; ++k ) - blockData[k] = j + k; + for ( int j = 0; j < blockSize; ++j ) + blockData[k] = i + j; message->AttachBlock( messageFactory.GetAllocator(), blockData, blockSize ); sender.SendMessage( 0, message ); }