Stricter checks for netname and node names.
- Node names should not be empty. - Net names should not contain slashes or start with a dot, because they are used in pathnames.
This commit is contained in:
parent
61006ced88
commit
6396f42d74
3 changed files with 18 additions and 2 deletions
|
|
@ -56,6 +56,9 @@ static char (*request_name[]) = {
|
|||
static splay_tree_t *past_request_tree;
|
||||
|
||||
bool check_id(const char *id) {
|
||||
if(!id || !*id)
|
||||
return false;
|
||||
|
||||
for(; *id; id++)
|
||||
if(!isalnum(*id) && *id != '_')
|
||||
return false;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue