src/SDL_assert.c
changeset 8377 3a7e8110201e
parent 8341 99c7c87774d5
parent 6759 b74da0b33530
child 8439 14d94a8a9fb6
     1.1 --- a/src/SDL_assert.c	Sun Dec 16 21:39:02 2012 -0500
     1.2 +++ b/src/SDL_assert.c	Sun Dec 16 22:02:01 2012 -0500
     1.3 @@ -128,6 +128,12 @@
     1.4  static SDL_assert_state
     1.5  SDL_PromptAssertion(const SDL_assert_data *data, void *userdata)
     1.6  {
     1.7 +#ifdef __WIN32__
     1.8 +    #define ENDLINE "\r\n"
     1.9 +#else
    1.10 +    #define ENDLINE "\n"
    1.11 +#endif
    1.12 +
    1.13      const char *envr;
    1.14      SDL_assert_state state = SDL_ASSERTION_ABORT;
    1.15      SDL_Window *window;
    1.16 @@ -152,7 +158,8 @@
    1.17          return SDL_ASSERTION_ABORT;
    1.18      }
    1.19      SDL_snprintf(message, SDL_MAX_LOG_MESSAGE,
    1.20 -                 "Assertion failure at %s (%s:%d), triggered %u %s:\r\n  '%s'",
    1.21 +                 "Assertion failure at %s (%s:%d), triggered %u %s:" ENDLINE
    1.22 +                    "  '%s'",
    1.23                   data->function, data->filename, data->linenum,
    1.24                   data->trigger_count, (data->trigger_count == 1) ? "time" : "times",
    1.25                   data->condition);