modules: only allow 'sink' and 'source' strings when parsing direction in config files

This commit is contained in:
Julian Bouzas
2019-12-12 11:48:39 -05:00
parent 0ad0c9fb9d
commit 7ac9c6359c
23 changed files with 25 additions and 25 deletions

View File

@@ -78,9 +78,9 @@ parse_properties (WpTomlTable *table, const char *name)
static guint
parse_endpoint_direction (const char *direction)
{
if (g_strcmp0 (direction, "input") == 0)
if (g_strcmp0 (direction, "sink") == 0)
return PW_DIRECTION_INPUT;
else if (g_strcmp0 (direction, "output") == 0)
else if (g_strcmp0 (direction, "source") == 0)
return PW_DIRECTION_OUTPUT;
g_return_val_if_reached (PW_DIRECTION_INPUT);