ReactOS  0.4.12-dev-43-g63b00d8
debug.c File Reference
#include "audiosrv.h"
#include <stdio.h>
Include dependency graph for debug.c:

Go to the source code of this file.

Functions

void logmsg (char *string,...)
 

Function Documentation

◆ logmsg()

void logmsg ( char string,
  ... 
)

Definition at line 7 of file debug.c.

Referenced by AppendAudioDeviceToList(), CreateAudioDeviceList(), CreateDeviceDescriptor(), DestroyAudioDeviceList(), ProcessExistingDevices(), RegisterForDeviceNotifications(), ServiceControlHandler(), ServiceMain(), StartAudioService(), StartSystemAudioServices(), WaitForService(), and wmain().

8 {
10 
11  FILE* debug_file = fopen("c:\\audiosrv-debug.txt", "a");
12 
13  if (debug_file)
14  {
15  va_start(args, string);
16  vfprintf(debug_file, string, args);
17  va_end(args);
18  fclose(debug_file);
19  }
20  else
21  {
22  char buf[256];
23  va_start(args, string);
24  vsprintf(buf, string, args);
25  OutputDebugStringA(buf);
26  va_end(args);
27  }
28 }
GLenum GLuint GLenum GLsizei const GLchar * buf
Definition: glext.h:7751
#define va_end(ap)
Definition: acmsvcex.h:90
char * va_list
Definition: acmsvcex.h:78
_Check_return_opt_ _CRTIMP int __cdecl fclose(_Inout_ FILE *_File)
_Check_return_ _CRTIMP FILE *__cdecl fopen(_In_z_ const char *_Filename, _In_z_ const char *_Mode)
int __cdecl vsprintf(char *_Dest, const char *_Format, va_list _Args)
Definition: sprintf.c:733
#define va_start(ap, A)
Definition: acmsvcex.h:91
_Check_return_opt_ _CRTIMP int __cdecl vfprintf(_Inout_ FILE *_File, _In_z_ _Printf_format_string_ const char *_Format, va_list _ArgList)
#define args
Definition: format.c:66
void WINAPI SHIM_OBJ_NAME() OutputDebugStringA(LPCSTR lpOutputString)
Definition: ignoredbgout.c:18