Fixed XML logger. EscapeString didn't from strings properly.
authorMarkus Kauppila
Sun, 03 Jul 2011 10:54:21 +0300
changeset 5737303be71c64aa
parent 5736 1008297b86e1
child 5738 8fc92ff2054b
Fixed XML logger. EscapeString didn't from strings properly.
test/test-automation/xml.c
     1.1 --- a/test/test-automation/xml.c	Fri Jul 01 22:15:23 2011 +0300
     1.2 +++ b/test/test-automation/xml.c	Sun Jul 03 10:54:21 2011 +0300
     1.3 @@ -159,6 +159,7 @@
     1.4  			break;
     1.5  		}
     1.6  	}
     1.7 +	totalSize += 1; // for '\0'
     1.8  
     1.9  	char *retBuffer = SDL_malloc(totalSize * sizeof(char));
    1.10  	if(retBuffer == NULL) {
    1.11 @@ -212,6 +213,8 @@
    1.12  
    1.13  	}
    1.14  
    1.15 +	retBuffer[retBufferCounter] = '\0';
    1.16 +
    1.17  	return retBuffer;
    1.18  }
    1.19