OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2003, 2006, 2007 Apple Inc. All rights reserved. | 2 * Copyright (C) 2003, 2006, 2007 Apple Inc. All rights reserved. |
3 * Copyright (C) 2007-2009 Torch Mobile, Inc. | 3 * Copyright (C) 2007-2009 Torch Mobile, Inc. |
4 * Copyright (C) 2011 University of Szeged. All rights reserved. | 4 * Copyright (C) 2011 University of Szeged. All rights reserved. |
5 * | 5 * |
6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
8 * are met: | 8 * are met: |
9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 16 matching lines...) Expand all Loading... |
27 | 27 |
28 // The vprintf_stderr_common function triggers this error in the Mac build. | 28 // The vprintf_stderr_common function triggers this error in the Mac build. |
29 // Feel free to remove this pragma if this file builds on Mac. | 29 // Feel free to remove this pragma if this file builds on Mac. |
30 // According to | 30 // According to |
31 // http://gcc.gnu.org/onlinedocs/gcc-4.2.1/gcc/Diagnostic-Pragmas.html#Diagnosti
c-Pragmas | 31 // http://gcc.gnu.org/onlinedocs/gcc-4.2.1/gcc/Diagnostic-Pragmas.html#Diagnosti
c-Pragmas |
32 // we need to place this directive before any data or functions are defined. | 32 // we need to place this directive before any data or functions are defined. |
33 #pragma GCC diagnostic ignored "-Wmissing-format-attribute" | 33 #pragma GCC diagnostic ignored "-Wmissing-format-attribute" |
34 | 34 |
35 #include "wtf/Assertions.h" | 35 #include "wtf/Assertions.h" |
36 | 36 |
| 37 #include <stdarg.h> |
| 38 #include <stdio.h> |
| 39 #include <stdlib.h> |
| 40 #include <string.h> |
| 41 #include <memory> |
37 #include "wtf/Compiler.h" | 42 #include "wtf/Compiler.h" |
38 #include "wtf/PtrUtil.h" | 43 #include "wtf/PtrUtil.h" |
39 #include "wtf/ThreadSpecific.h" | 44 #include "wtf/ThreadSpecific.h" |
40 #include "wtf/Threading.h" | 45 #include "wtf/Threading.h" |
41 #include <memory> | |
42 #include <stdarg.h> | |
43 #include <stdio.h> | |
44 #include <stdlib.h> | |
45 #include <string.h> | |
46 | 46 |
47 #if OS(MACOSX) | 47 #if OS(MACOSX) |
48 #include <AvailabilityMacros.h> | 48 #include <AvailabilityMacros.h> |
49 #if __MAC_OS_X_VERSION_MIN_REQUIRED >= 1080 | 49 #if __MAC_OS_X_VERSION_MIN_REQUIRED >= 1080 |
50 #define WTF_USE_APPLE_SYSTEM_LOG 1 | 50 #define WTF_USE_APPLE_SYSTEM_LOG 1 |
51 #include <asl.h> | 51 #include <asl.h> |
52 #endif | 52 #endif |
53 #endif // OS(MACOSX) | 53 #endif // OS(MACOSX) |
54 | 54 |
55 #if COMPILER(MSVC) | 55 #if COMPILER(MSVC) |
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
248 | 248 |
249 } // namespace WTF | 249 } // namespace WTF |
250 #endif // !LOG_DISABLED | 250 #endif // !LOG_DISABLED |
251 | 251 |
252 void WTFLogAlways(const char* format, ...) { | 252 void WTFLogAlways(const char* format, ...) { |
253 va_list args; | 253 va_list args; |
254 va_start(args, format); | 254 va_start(args, format); |
255 vprintf_stderr_with_trailing_newline(format, args); | 255 vprintf_stderr_with_trailing_newline(format, args); |
256 va_end(args); | 256 va_end(args); |
257 } | 257 } |
OLD | NEW |