I do have an idea why these settings are not set. It’s quite simple, really. Take a look at the PHP manual: $HTTP_SERVER_VARS
is deprecated. The line in question should look like this:
$curdir = "https://" . $_SERVER['HTTP_HOST'] . dirname($_SERVER['PHP_SELF']);