Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(844)

Side by Side Diff: src/ports/SkDebug_win.cpp

Issue 99173003: Use lowercase windows.h in includes to fix Windows cross compilation using mingw. (Closed)
Patch Set: Created 7 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/gpu/gl/win/SkNativeGLContext_win.cpp ('k') | src/utils/win/SkAutoCoInitialize.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 1
2 /* 2 /*
3 * Copyright 2010 Google Inc. 3 * Copyright 2010 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 9
10 10
11 #include "SkTypes.h" 11 #include "SkTypes.h"
12 12
13 static const size_t kBufferSize = 2048; 13 static const size_t kBufferSize = 2048;
14 14
15 #include <stdarg.h> 15 #include <stdarg.h>
16 #include <stdio.h> 16 #include <stdio.h>
17 #include <Windows.h> 17 #include <windows.h>
18 18
19 void SkDebugf(const char format[], ...) { 19 void SkDebugf(const char format[], ...) {
20 char buffer[kBufferSize + 1]; 20 char buffer[kBufferSize + 1];
21 va_list args; 21 va_list args;
22 22
23 va_start(args, format); 23 va_start(args, format);
24 vprintf(format, args); 24 vprintf(format, args);
25 va_end(args); 25 va_end(args);
26 // When we crash on Windows we often are missing a lot of prints. Since we d on't really care 26 // When we crash on Windows we often are missing a lot of prints. Since we d on't really care
27 // about SkDebugf performance we flush after every print. 27 // about SkDebugf performance we flush after every print.
28 fflush(stdout); 28 fflush(stdout);
29 29
30 va_start(args, format); 30 va_start(args, format);
31 vsnprintf(buffer, kBufferSize, format, args); 31 vsnprintf(buffer, kBufferSize, format, args);
32 va_end(args); 32 va_end(args);
33 33
34 OutputDebugStringA(buffer); 34 OutputDebugStringA(buffer);
35 } 35 }
OLDNEW
« no previous file with comments | « src/gpu/gl/win/SkNativeGLContext_win.cpp ('k') | src/utils/win/SkAutoCoInitialize.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698