Bug in 5.0.5-dev and 5.1-beta

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Tony Marston

    Bug in 5.0.5-dev and 5.1-beta

    I have just found a bug in 5.0.5-dev and 5.1-beta which occurs under the
    following circumstances:
    - you are using a custom session handler to write all session data to the
    database.
    - you use a shared resource for the database connection (i.e. after
    connecting to the database to read the session data you use the same
    connection to write to the database).

    The problem appears to be that the order of events when a script terminates
    has been altered so that it releases all resources before writing out the
    session data. This means that the database connection resource is no longer
    available which results in a "couldn't fetch mysqli" error.

    I have found that putting an explicit session_write_c lose() at the end of my
    script cures the problem.

    Check it out at http://bugs.php.net/bug.php?id=33635

    --
    Tony Marston

    This is Tony Marston's web site, containing personal information plus pages devoted to the Uniface 4GL development language, XML and XSL, PHP and MySQL, and a bit of COBOL




Working...