ntdll: Translate signal to trap when trap code is 0 on ARM.
[wine.git] / dlls / vssapi / main.c
blob7ac0adb5639da64891dffc5db8f40a7feb27f690
1 /*
2 * Copyright 2014 Hans Leidekker for CodeWeavers
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
19 #include "config.h"
20 #include <stdarg.h>
21 #include "windef.h"
22 #include "winbase.h"
23 #include "vss.h"
24 #include "vswriter.h"
25 #include "vsbackup.h"
26 #include "wine/debug.h"
28 WINE_DEFAULT_DEBUG_CHANNEL( vssapi );
30 #undef __thiscall
31 #ifdef __i386__ /* thiscall functions are i386-specific */
33 #define THISCALL(func) __thiscall_ ## func
34 #define THISCALL_NAME(func) __ASM_NAME("__thiscall_" #func)
35 #define __thiscall __stdcall
36 #define DEFINE_THISCALL_WRAPPER(func,args) \
37 extern void THISCALL(func)(void); \
38 __ASM_GLOBAL_FUNC(__thiscall_ ## func, \
39 "popl %eax\n\t" \
40 "pushl %ecx\n\t" \
41 "pushl %eax\n\t" \
42 "jmp " __ASM_NAME(#func) __ASM_STDCALL(args) )
43 #else /* __i386__ */
45 #define THISCALL(func) func
46 #define THISCALL_NAME(func) __ASM_NAME(#func)
47 #define __thiscall __cdecl
48 #define DEFINE_THISCALL_WRAPPER(func,args) /* nothing */
50 #endif /* __i386__ */
52 struct CVssWriter
54 void **vtable;
57 /******************************************************************
58 * ??0CVssWriter@@QAE@XZ (VSSAPI.@)
60 DEFINE_THISCALL_WRAPPER( VSSAPI_CVssWriter_default_ctor, 4 )
61 struct CVssWriter * __thiscall VSSAPI_CVssWriter_default_ctor( struct CVssWriter *writer )
63 FIXME( "%p\n", writer );
64 writer->vtable = NULL;
65 return writer;
68 /******************************************************************
69 * ??1CVssWriter@@UAE@XZ (VSSAPI.@)
71 DEFINE_THISCALL_WRAPPER( VSSAPI_CVssWriter_dtor, 4 )
72 void __thiscall VSSAPI_CVssWriter_dtor( struct CVssWriter *writer )
74 FIXME( "%p\n", writer );
77 /******************************************************************
78 * ?Initialize@CVssWriter@@QAGJU_GUID@@PBGW4VSS_USAGE_TYPE@@W4VSS_SOURCE_TYPE@@W4_VSS_APPLICATION_LEVEL@@KW4VSS_ALTERNATE_WRITER_STATE@@_N@Z
80 DEFINE_THISCALL_WRAPPER( VSSAPI_CVssWriter_Initialize, 52 )
81 HRESULT __thiscall VSSAPI_CVssWriter_Initialize( struct CVssWriter *writer, VSS_ID id,
82 LPCWSTR name, VSS_USAGE_TYPE usage_type, VSS_SOURCE_TYPE source_type,
83 VSS_APPLICATION_LEVEL level, DWORD timeout, VSS_ALTERNATE_WRITER_STATE alt_writer_state,
84 BOOL throttle, LPCWSTR instance )
86 FIXME( "%p, %s, %s, %u, %u, %u, %u, %u, %d, %s\n", writer, debugstr_guid(&id),
87 debugstr_w(name), usage_type, source_type, level, timeout, alt_writer_state,
88 throttle, debugstr_w(instance) );
89 return S_OK;
92 /******************************************************************
93 * ?Subscribe@CVssWriter@@QAGJK@Z
95 DEFINE_THISCALL_WRAPPER( VSSAPI_CVssWriter_Subscribe, 8 )
96 HRESULT __thiscall VSSAPI_CVssWriter_Subscribe( struct CVssWriter *writer, DWORD flags )
98 FIXME( "%p, %x\n", writer, flags );
99 return S_OK;
102 /******************************************************************
103 * ?Unsubscribe@CVssWriter@@QAGJXZ
105 DEFINE_THISCALL_WRAPPER( VSSAPI_CVssWriter_Unsubscribe, 4 )
106 HRESULT __thiscall VSSAPI_CVssWriter_Unsubscribe( struct CVssWriter *writer )
108 FIXME( "%p\n", writer );
109 return S_OK;
112 HRESULT WINAPI CreateVssBackupComponentsInternal(IVssBackupComponents **backup)
114 FIXME("%p\n", backup);
115 return E_NOTIMPL;
118 /******************************************************************
119 * ?CreateVssBackupComponents@@YGJPAPAVIVssBackupComponents@@@Z
121 HRESULT WINAPI VSSAPI_CreateVssBackupComponents( IVssBackupComponents **backup )
123 FIXME( "%p\n", backup );
125 return CreateVssBackupComponentsInternal(backup);