server/proxy: Use new parse_string_array_from_str implementation (using ArrayList)
This commit is contained in:
parent
3a750810f7
commit
96616bb18c
@ -22,6 +22,9 @@
|
||||
#include "pf_server.h"
|
||||
#include "pf_config.h"
|
||||
#include "pf_log.h"
|
||||
#include "pf_filters.h"
|
||||
|
||||
#include <winpr/collections.h>
|
||||
|
||||
#define TAG PROXY_TAG("server")
|
||||
|
||||
@ -59,15 +62,15 @@ int main(int argc, char* argv[])
|
||||
{
|
||||
WLog_INFO(TAG, "Channels mode: WHITELIST");
|
||||
|
||||
for (i = 0; i < config->AllowedChannelsCount; i++)
|
||||
WLog_INFO(TAG, "Allowing %s", config->AllowedChannels[i]);
|
||||
for (i = 0; i < ArrayList_Count(config->AllowedChannels); i++)
|
||||
WLog_INFO(TAG, "Allowing %s", (char*) ArrayList_GetItem(config->AllowedChannels, i));
|
||||
}
|
||||
else
|
||||
{
|
||||
WLog_INFO(TAG, "Channels mode: BLACKLIST");
|
||||
|
||||
for (i = 0; i < config->BlockedChannelsCount; i++)
|
||||
WLog_INFO(TAG, "Blocking %s", config->BlockedChannels[i]);
|
||||
for (i = 0; i < ArrayList_Count(config->BlockedChannels); i++)
|
||||
WLog_INFO(TAG, "Blocking %s", (char*) ArrayList_GetItem(config->BlockedChannels, i));
|
||||
}
|
||||
|
||||
status = pf_server_start(config);
|
||||
|
@ -58,8 +58,8 @@ struct proxy_config
|
||||
/* channels */
|
||||
BOOL WhitelistMode;
|
||||
|
||||
char** AllowedChannels;
|
||||
UINT32 AllowedChannelsCount;
|
||||
wArrayList* AllowedChannels;
|
||||
wArrayList* BlockedChannels;
|
||||
|
||||
/* filters */
|
||||
filters_list* Filters;
|
||||
|
Loading…
Reference in New Issue
Block a user