Skip to content

Commit

Permalink
public: allow matching anything in matchpattern
Browse files Browse the repository at this point in the history
  • Loading branch information
a1batross committed Jul 5, 2023
1 parent cd46ad1 commit 4031f5c
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion public/crtlib.c
Original file line number Diff line number Diff line change
Expand Up @@ -954,7 +954,12 @@ char *COM_ParseFileSafe( char *data, char *token, const int size, unsigned int f

int matchpattern( const char *in, const char *pattern, qboolean caseinsensitive )
{
return matchpattern_with_separator( in, pattern, caseinsensitive, "/\\:", false );
const char *separators = "/\\:";

if( !Q_strcmp( pattern, "*" ))
separators = "";

return matchpattern_with_separator( in, pattern, caseinsensitive, separators, false );
}

// wildcard_least_one: if true * matches 1 or more characters
Expand Down

0 comments on commit 4031f5c

Please sign in to comment.