Comment 5 for bug 1734786

Revision history for this message
Bryce Harrington (bryce) wrote : Re: session.use_trans_sid value parsed incorrectly

I think I agree with Andreas that it does indeed look like that same bug report. There is also a dupe bug that describes the issue more closely to how it's described in this one:

    https://bugs.php.net/bug.php?id=54051

> This is not that bug. The problem here is with setting value, not with getting it.

There may be misunderstanding, the 'get' is the function to read and interpret the value you set in the config file. So, 'get' from the computer's perspective, not from ours. :-)

Also, I think the behavior is not incorrect, even if it appears to be so. For example, if you set to "On", the value switches:

    triage-kinetic+22.10:~$ cat .user.ini
    session.use_trans_sid = On
    triage-kinetic+22.10:~$ php -c .user.ini -r 'echo "session.use_trans_sid = \"".ini_get("session.use_trans_sid")."\"\n";'
    session.use_trans_sid = "1"

Upstream's comment on the aforementioned bug report explains what's going on:

"Yes, this isn't completely consistent. An empty string is the same as Off. It
doesn't display the same as the boolean flags in phpinfo() because it isn't a
boolean since it can take numeric values. 0, "" and Off all mean the same thing
here. So it is purely aesthetic, but we should still go through and clean this up
at some point."

So, it's a known issue upstream, behaviorally correct if aesthetically awkward. I don't think this is something we'd need to address locally in Ubuntu, and would recommend engaging upstream for a fix.