Added a newline to OutputDebugString(), fixes output on Visual Studio 2008
authorSam Lantinga <slouken@libsdl.org>
Thu, 23 May 2013 23:27:48 -0700
changeset 721541e739a52f69
parent 7214 5b31583ecf9e
child 7216 3586fc0ba156
Added a newline to OutputDebugString(), fixes output on Visual Studio 2008
src/SDL_log.c
     1.1 --- a/src/SDL_log.c	Thu May 23 18:45:14 2013 -0400
     1.2 +++ b/src/SDL_log.c	Thu May 23 23:27:48 2013 -0700
     1.3 @@ -299,9 +299,9 @@
     1.4          size_t length;
     1.5          LPTSTR tstr;
     1.6  
     1.7 -        length = SDL_strlen(SDL_priority_prefixes[priority]) + 2 + SDL_strlen(message) + 1;
     1.8 +        length = SDL_strlen(SDL_priority_prefixes[priority]) + 2 + SDL_strlen(message) + 1 + 1;
     1.9          output = SDL_stack_alloc(char, length);
    1.10 -        SDL_snprintf(output, length, "%s: %s", SDL_priority_prefixes[priority], message);
    1.11 +        SDL_snprintf(output, length, "%s: %s\n", SDL_priority_prefixes[priority], message);
    1.12          tstr = WIN_UTF8ToString(output);
    1.13          OutputDebugString(tstr);
    1.14          SDL_free(tstr);