* (bug 3318) Restrict color escape characters to alphanumerics
This commit is contained in:
parent
da29118ae0
commit
60260f1c60
2 changed files with 17 additions and 1 deletions
|
@ -330,7 +330,7 @@ extern vec4_t colorMdGrey;
|
|||
extern vec4_t colorDkGrey;
|
||||
|
||||
#define Q_COLOR_ESCAPE '^'
|
||||
#define Q_IsColorString(p) ( p && *(p) == Q_COLOR_ESCAPE && *((p)+1) && *((p)+1) != Q_COLOR_ESCAPE )
|
||||
#define Q_IsColorString(p) ( p && *(p) == Q_COLOR_ESCAPE && *((p)+1) && isalnum(*((p)+1)) ) // ^[0-9a-zA-Z]
|
||||
|
||||
#define COLOR_BLACK '0'
|
||||
#define COLOR_RED '1'
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue