1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
|
#include <stdio.h>
#include <winpr/crt.h>
#include <winpr/windows.h>
#include <freerdp/client/channels.h>
#include <freerdp/channels/rdpsnd.h>
int TestClientChannels(int argc, char* argv[])
{
DWORD dwFlags = 0;
FREERDP_ADDIN** ppAddins = NULL;
WINPR_UNUSED(argc);
WINPR_UNUSED(argv);
dwFlags = FREERDP_ADDIN_DYNAMIC;
printf("Enumerate all\n");
ppAddins = freerdp_channels_list_addins(NULL, NULL, NULL, dwFlags);
for (size_t index = 0; ppAddins[index] != NULL; index++)
{
FREERDP_ADDIN* pAddin = ppAddins[index];
printf("Addin: Name: %s Subsystem: %s Type: %s\n", pAddin->cName, pAddin->cSubsystem,
pAddin->cType);
}
freerdp_channels_addin_list_free(ppAddins);
printf("Enumerate rdpsnd\n");
ppAddins = freerdp_channels_list_addins(RDPSND_CHANNEL_NAME, NULL, NULL, dwFlags);
for (size_t index = 0; ppAddins[index] != NULL; index++)
{
FREERDP_ADDIN* pAddin = ppAddins[index];
printf("Addin: Name: %s Subsystem: %s Type: %s\n", pAddin->cName, pAddin->cSubsystem,
pAddin->cType);
}
freerdp_channels_addin_list_free(ppAddins);
#if defined(CHANNEL_TSMF_CLIENT)
printf("Enumerate tsmf video\n");
ppAddins = freerdp_channels_list_addins("tsmf", NULL, "video", dwFlags);
for (size_t index = 0; ppAddins[index] != NULL; index++)
{
FREERDP_ADDIN* pAddin = ppAddins[index];
printf("Addin: Name: %s Subsystem: %s Type: %s\n", pAddin->cName, pAddin->cSubsystem,
pAddin->cType);
}
freerdp_channels_addin_list_free(ppAddins);
#endif
ppAddins = freerdp_channels_list_addins("unknown", NULL, NULL, dwFlags);
for (size_t index = 0; ppAddins[index] != NULL; index++)
{
FREERDP_ADDIN* pAddin = ppAddins[index];
printf("Addin: Name: %s Subsystem: %s Type: %s\n", pAddin->cName, pAddin->cSubsystem,
pAddin->cType);
}
freerdp_channels_addin_list_free(ppAddins);
printf("Enumerate static addins\n");
dwFlags = FREERDP_ADDIN_STATIC;
ppAddins = freerdp_channels_list_addins(NULL, NULL, NULL, dwFlags);
for (size_t index = 0; ppAddins[index] != NULL; index++)
{
FREERDP_ADDIN* pAddin = ppAddins[index];
printf("Addin: Name: %s Subsystem: %s Type: %s\n", pAddin->cName, pAddin->cSubsystem,
pAddin->cType);
}
freerdp_channels_addin_list_free(ppAddins);
return 0;
}
|