aboutsummaryrefslogtreecommitdiff
path: root/sway/criteria.c
diff options
context:
space:
mode:
Diffstat (limited to 'sway/criteria.c')
-rw-r--r--sway/criteria.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sway/criteria.c b/sway/criteria.c
index 5ad48145..f2db6c18 100644
--- a/sway/criteria.c
+++ b/sway/criteria.c
@@ -208,7 +208,7 @@ static bool criteria_matches_view(struct criteria *criteria,
if (criteria->workspace) {
struct sway_workspace *ws = view->container->workspace;
- if (!ws || strcmp(ws->name, criteria->workspace) != 0) {
+ if (!ws || regex_cmp(ws->name, criteria->workspace) != 0) {
return false;
}
}
@@ -515,7 +515,7 @@ static bool parse_token(struct criteria *criteria, char *name, char *value) {
}
break;
case T_WORKSPACE:
- criteria->workspace = strdup(effective_value);
+ generate_regex(&criteria->workspace, effective_value);
break;
case T_INVALID:
break;