[drupal-devel] [bug] Session system - fix for NULL uid

Cvbge drupal-devel at drupal.org
Fri Aug 19 19:39:05 UTC 2005


Issue status update for 
http://drupal.org/node/29143
Post a follow up: 
http://drupal.org/project/comments/add/29143

 Project:      Drupal
 Version:      4.5.5
 Component:    other
 Category:     bug reports
 Priority:     critical
 Assigned to:  Anonymous
 Reported by:  Cvbge
 Updated by:   Cvbge
 Status:       patch (code needs review)

I believe the SQL query change is better in this case, because it fixes
the problem, does not need schema change and makes 4.5 version the same
as 4.6.




Cvbge



Previous comments:
------------------------------------------------------------------------

Thu, 18 Aug 2005 19:39:17 +0000 : Cvbge

Attachment: http://drupal.org/files/issues/session-uid.inc (955 bytes)

On fresh install session table is empty and session.inc tries to insert
a row. But it ommits uid field which is NOT NULL and inserting fails.
Attached patch makes it to have the same behaviour as 4.6




------------------------------------------------------------------------

Thu, 18 Aug 2005 22:13:34 +0000 : Dries

Patch doesn't apply because it ends with '.inc'.  Maybe better to use
uid int(11) NOT NULL default '0' in the table definition?




------------------------------------------------------------------------

Fri, 19 Aug 2005 13:25:37 +0000 : Cvbge

Attachment: http://drupal.org/files/issues/session-uid.inc.diff (955 bytes)

I can't change schema definition because that'd mean that db update is
needed when upgrading from 4.5.5 to 4.5.6.
As I said (although not directly) 4.6 and later does not have this bug.



Heh, at first I didn't understand what's with the .inc extension...




------------------------------------------------------------------------

Fri, 19 Aug 2005 14:07:20 +0000 : chx

You can change schema IMO. It has happened already, we extended locale
field size in a minor release. Just nothing major. If you need a rule
of thumb: column attribute changes are OK but nothing else.







More information about the drupal-devel mailing list