Skip to content

Commit

Permalink
porting to vc6
Browse files Browse the repository at this point in the history
  • Loading branch information
stephen.nil committed Nov 7, 2009
1 parent 08e30e1 commit 08f9507
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions spserver/spmsgdecoder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -261,8 +261,8 @@ int SP_DotTermChunkMsgDecoder :: decode( SP_Buffer * inBuffer )

char * SP_DotTermChunkMsgDecoder :: getMsg()
{
int totalSize = 0;
for( int i = 0; i < mList->getCount(); i++ ) {
int i = 0, totalSize = 0;
for( i = 0; i < mList->getCount(); i++ ) {
SP_Buffer * item = (SP_Buffer*)mList->getItem( i );
totalSize += item->getSize();
}
Expand All @@ -272,13 +272,13 @@ char * SP_DotTermChunkMsgDecoder :: getMsg()

char * des = ret, * src = NULL;

for( int i = 0; i < mList->getCount(); i++ ) {
for( i = 0; i < mList->getCount(); i++ ) {
SP_Buffer * item = (SP_Buffer*)mList->getItem( i );
memcpy( des, item->getRawBuffer(), item->getSize() );
des += item->getSize();
}

for( int i = 0; i < mList->getCount(); i++ ) {
for( i = 0; i < mList->getCount(); i++ ) {
SP_Buffer * item = (SP_Buffer*)mList->getItem( i );
delete item;
}
Expand Down

0 comments on commit 08f9507

Please sign in to comment.