Opened 8 years ago

Closed 2 years ago

Last modified 2 years ago

#65 closed defect (fixed)

Cannot redeclare class

Reported by: coredump Owned by: moo
Priority: critical Milestone: 1.3.0
Component: cacher Version: 1.2-dev
Keywords: Cc:
Application: vBulletin PHP Version: 5.2.0
Other Exts: SAPI: Irrelevant
Probability: Blocked By:
Blocking:

Description

I'm getting the following error message in the Apache error log while running vBulletin 3.6.4.

PHP Fatal error:  Cannot redeclare class vb_datamanager_user
 in /home/path-removed/includes/class_dm_user.php on line 31, referer: http://domain-removed/showthread.php?t=13755

A snippet from class_dm_user.php looks like:

if (!class_exists('vB_DataManager'))
{
        exit;
}

define('SALT_LENGTH', 3);

class vB_DataManager_User extends vB_DataManager # <- line #31
{

Change History (15)

comment:1 Changed 8 years ago by coredump

Also, it seems that class_dm_user.php is included somewhere conditionally as I even can not find any explicit reference to it (there are a number of class_dm_*.php files, obviously the required filename is generated on the fly).

comment:3 Changed 8 years ago by coredump

Forgot to mention that I use the latest svn on Linux+Apache(mod_php).

comment:4 Changed 8 years ago by moo

can u pls upgrade your php? and or update the ticket about the version

comment:5 Changed 8 years ago by coredump

Sorry, forgot to mention that it's the latest version - php 5.2.0.

comment:6 Changed 8 years ago by moo

  • PHP Version set to 5.2.0

comment:7 Changed 8 years ago by judas_iscariote

Unfortunately, Vbulletin is commercial software and we dont have licenses to add it into the stack of tested applications..

So, reproduce code is needed.

comment:8 Changed 7 years ago by judas_iscariote

ok, the fine folks at "Jelsoft" provided us a license in order to add this bulletin board to the test suite, however. Im unable to reproduce your problem, with php 5.2.2-dev + Xcache svn 1.2.1-dev + lighttpd

where should I click to get this error ?

comment:9 Changed 7 years ago by moo

  • Application set to vBulletin

comment:10 Changed 7 years ago by coredump

I do not know why but now I'm unable to reproduce it either. I did not even upgrade anything (php, xcache, apache), just enabled xcache and restarted apache. However there were some significant modifications of the forum since than (few plugins installed, few uninstalled, some custom hacks, heavy style changes). Unfortunately now it is very difficult to restore it to the same state when this error message appeared.
I'll let it run with xcache enabled for a while and see if it will happen again.

comment:11 Changed 7 years ago by moo

hrm... plugins/hacks, that's a headache to reproduce, u may reproduce it some day while we still can't with our own copy

comment:12 Changed 7 years ago by moo

  • Milestone set to 1.2.2
  • pending set to 1
  • SAPI set to Irrelevant

can u pls check if it's still a problem in 1.2.1?

comment:1 Changed 7 years ago by trac-robot

  • pending changed from 1 to 0
  • Status changed from new to closed

This ticket was closed automatically by the system. It was previously set to a Pending status and hasn't been updated within 28 days.

comment:2 Changed 2 years ago by moo

  • Status changed from closed to reopened

comment:3 Changed 2 years ago by moo

  • Resolution set to fixed
  • Status changed from reopened to closed

should have been fixed since PHP 5.3 and some version of XCache

comment:4 Changed 2 years ago by moo

  • Milestone changed from 1.2.2 to 1.3.0

since XCache-1.3.0 which bring PHP 5.3 support

Note: See TracTickets for help on using tickets.