Commit cf6abd90 authored by Leigh B. Stoller's avatar Leigh B. Stoller

Tweak previous revision.

parent c4d4d37c
......@@ -387,9 +387,14 @@ function LOGGEDINORDIE($uid, $modifier = 0, $login_url = NULL) {
if ($uid == "") {
$uid = $HTTP_COOKIE_VARS[$TBNAMECOOKIE];
# Verify valid string (no special chars like single/double quotes!).
if (! preg_match("/^[-\w]+$/", $uid)) {
TBERROR("LOGGEDINORDIE: Illegal characters in $uid", 1);
if ($uid == "") {
$uid = FALSE;
}
else {
# Verify valid string (no special chars like single/double quotes!)
if (! preg_match("/^[-\w]+$/", $uid)) {
TBERROR("LOGGEDINORDIE: Illegal characters in $uid", 1);
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment