Fix debugging on WP with a huge hack

This commit is contained in:
Cameron Gutman 2014-01-28 19:24:04 -05:00 committed by Michelle Bergeron
parent 41fab76461
commit c04a8e9b4c
3 changed files with 14 additions and 3 deletions

View File

@ -5,9 +5,6 @@
#include "PlatformSockets.h"
#include "Video.h"
#include <stdio.h>
#define Limelog printf
char* allocateConfigDataForStreamConfig(PSTREAM_CONFIGURATION streamConfig);
int getConfigDataSize(PSTREAM_CONFIGURATION streamConfig);

View File

@ -21,6 +21,16 @@
# define LC_POSIX
#endif
#include <stdio.h>
#ifdef LC_WINDOWS_PHONE
extern WCHAR DbgBuf[512];
#define Limelog(s, ...) \
swprintf(DbgBuf, sizeof(DbgBuf) / sizeof(WCHAR), L ## s, ##__VA_ARGS__); \
OutputDebugString(DbgBuf)
#else
#define Limelog printf
#endif
#if defined(LC_WINDOWS_PHONE) || defined(LC_WINDOWS)
#include <crtdbg.h>
#define LC_ASSERT _ASSERTE

View File

@ -12,6 +12,10 @@ VOID WINAPI ApcFunc(ULONG_PTR parameter) {
}
#endif
#if defined(LC_WINDOWS_PHONE)
WCHAR DbgBuf[512];
#endif
#ifdef LC_WINDOWS
DWORD WINAPI ThreadProc(LPVOID lpParameter) {
struct thread_context *ctx = (struct thread_context *)lpParameter;