Ticket #1484068 (closed Bugs: fixed)

Opened 2 years ago

Last modified 21 months ago

Bug in database handling for postgres

Reported by: bobtfish Owned by: thomasb
Priority: 5 Milestone: 0.1-rc1
Component: Database Version: 0.1-beta
Severity: critical Keywords:
Cc:

Description

Took me a while of tracing through the application to work this one out.. The function which has a problem is 'insert_id' in program/include/rcube_db.inc

For postgresql, no value is returned from the switch statement, which implicitly falls through, runs the query 'SELECT @@IDENTITY' which generates an exception, and then returns this exception..

This causes a row in the 'identity' table to not be created when a user is created and you are using the 'virtuser_query' config setting.

Trivial patch to fix attached.

Attachments

roundcube-postgres-bugfix.patch (0.5 kB) - added by bobtfish 2 years ago.
Fix a bug in the handling of postgres databases.

Change History

Changed 2 years ago by bobtfish

Fix a bug in the handling of postgres databases.

Changed 21 months ago by thomasb

  • owner set to thomasb
  • milestone set to 0.1-rc1

Changed 21 months ago by thomasb

  • status changed from new to closed
  • resolution set to fixed

Fixed in Trunk (r504)

Note: See TracTickets for help on using tickets.