How I discovered a critical Drupal 5.13 PHP incopatibility

Submitted by fabio on Sat, 2008-12-13 10:00.

Maybe you already know that, in some countries, the number 13 is associated with bad luck and some people are really frightened of it.

Personally I don't care much of all this stuff.. I don't believe such things.

But seems that Drupal version 5.13 had pretty an unlucky life given that it had been out just for a couple of days and later replaced by the new version 5.14.

But.. what happened? Hem.. well.. if Drupal 5.13 had such a short life it's because of me.

Just a couple of hours after the release of Drupal 5.13, I installed it here on my personal website. Soon after I noticed a very strange error during logins:

warning: Wrong parameter count for session_set_cookie_params() in /path/to/drupal/includes/session.inc on line 102.

As my Drupal install is pretty simple (no complex modules) I already knew that there was something bad with the new version.

Immediately I opened a bug report about my problem and asked for help at #drupal on irc.

Chx, one of the main Drupal core developers, immediately told me that I discovered something bad and started investigating the problem.

Turns out that this patch, which had been added to increase session regeneration security, contained some PHP 5.2 specific code which obviously couldn't work on PHP 4.

Yes, yes.. I know that PHP 4 has been discontinued anyway there are still tons of people using it and Drupal 5.x supports it: the bug I discovered was critical.

That's why drumm and Gábor Hojtsy, maintainers of drupal 5.x and 6.x, immediately removed the bad patch to solve the bug.

Just a day later new Drupal versions 5.14 and 6.7 had been released to fix the issue I found (just that actually).

Kudos to all the developers and maintainers for the fast reaction to the problem.

Post new comment

The content of this field is kept private and will not be shown publicly.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd> <pre> <img> <h2> <h3> <h4> <b>
  • Lines and paragraphs break automatically.
  • Images can be added to this post.
  • You may use [inline:xx] tags to display uploaded files or images inline.
  • You may insert videos with [video:URL]

More information about formatting options