include/functions_cookie: use proper brackets for offset access

Fixes #1134
This commit is contained in:
Tomas Krizek
2019-12-03 21:56:44 +01:00
committed by Pierrick Le Gall
parent 29cc543a14
commit 8573e35b18
2 changed files with 4 additions and 4 deletions

View File

@@ -54,7 +54,7 @@ function cookie_path()
$scr = substr($scr,0,strrpos( $scr,'/'));
// add a trailing '/' if needed
if ((strlen($scr) == 0) or ($scr{strlen($scr)-1} !== '/'))
if ((strlen($scr) == 0) or ($scr[strlen($scr)-1] !== '/'))
{
$scr .= '/';
}