Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
emulab
emulab-devel
Commits
ccab8340
Commit
ccab8340
authored
Oct 11, 2004
by
Leigh B. Stoller
Browse files
Commit old change: In dbcheck, if the regex from table_regex is not
"anchored" (^xxx$) then force it to be anchored by wrapping it.
parent
320dfab4
Changes
1
Hide whitespace changes
Inline
Side-by-side
db/libdb.pm.in
View file @
ccab8340
...
...
@@ -4242,6 +4242,13 @@ sub TBcheck_dbslot($$$;$)
" Functional DB checks not implemented: $table/$column!\n");
}
# Make sure the regex is anchored. Its a mistake not to be!
$check = "^" . $check
if (! ($check =~ /^\^/));
$check = $check . "\$"
if (! ($check =~ /\Q$/));
# Check regex.
return 0
if (! ("$token" =~ /$check/));
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment