winedbg: Don't dereference possibly NULL thread pointer.
[wine/zf.git] / dlls / msvcrtd / debug.c
blob137f1bfc4ff5c25ae9dac9607fa591c4ba7b83b5
1 /*
2 * msvcrtd.dll debugging code
4 * Copyright (C) 2003 Adam Gundy
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
21 #include "msvcrt.h"
23 int _crtAssertBusy = -1;
24 int _crtBreakAlloc = -1;
25 int _crtDbgFlag = 0;
28 /*********************************************************************
29 * _CrtSetDumpClient (MSVCRTD.@)
31 void * CDECL _CrtSetDumpClient(void *dumpClient)
33 return NULL;
37 /*********************************************************************
38 * _CrtSetReportHook (MSVCRTD.@)
40 void * CDECL _CrtSetReportHook(void *reportHook)
42 return NULL;
46 /*********************************************************************
47 * _CrtSetReportMode (MSVCRTD.@)
49 int CDECL _CrtSetReportMode(int reportType, int reportMode)
51 return 0;
55 /*********************************************************************
56 * _CrtSetBreakAlloc (MSVCRTD.@)
58 int CDECL _CrtSetBreakAlloc(int new)
60 int old = _crtBreakAlloc;
61 _crtBreakAlloc = new;
62 return old;
65 /*********************************************************************
66 * _CrtSetDbgFlag (MSVCRTD.@)
68 int CDECL _CrtSetDbgFlag(int new)
70 int old = _crtDbgFlag;
71 _crtDbgFlag = new;
72 return old;
76 /*********************************************************************
77 * _CrtDbgReport (MSVCRTD.@)
79 int WINAPIV _CrtDbgReport(int reportType, const char *filename, int linenumber,
80 const char *moduleName, const char *format, ...)
82 return 0;
85 /*********************************************************************
86 * _CrtDumpMemoryLeaks (MSVCRTD.@)
88 int CDECL _CrtDumpMemoryLeaks(void)
90 return 0;
93 /*********************************************************************
94 * _CrtCheckMemory (MSVCRTD.@)
96 int CDECL _CrtCheckMemory(void)
98 /* Note: maybe we could call here our heap validating functions ? */
99 return TRUE;
103 /*********************************************************************
104 * __p__crtAssertBusy (MSVCRTD.@)
106 int * CDECL __p__crtAssertBusy(void)
108 return &_crtAssertBusy;
111 /*********************************************************************
112 * __p__crtBreakAlloc (MSVCRTD.@)
114 int * CDECL __p__crtBreakAlloc(void)
116 return &_crtBreakAlloc;
119 /*********************************************************************
120 * __p__crtDbgFlag (MSVCRTD.@)
122 int * CDECL __p__crtDbgFlag(void)
124 return &_crtDbgFlag;