Incompatible with smtp.module (redeclared function)

Andreas Wolf - November 19, 2006 - 00:55
Project:Return-Path
Version:6.x-1.0
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:active
Description

[Sun Nov 19 01:49:07 2006] [error] [client 192.168.42.xxx] PHP Fatal error: Cannot redeclare user_mail_wrapper() (previously declared in /srv/www/vhosts/mypath/htdocs/modules/returnpath/returnpath.module:22) in /srv/www/vhosts/mypath/htdocs/modules/smtp/smtp.module on line 197

#1

budda - November 19, 2006 - 01:21
Status:active» by design

Don't install both modules together. They both need the same Drupal function to work.

#2

greggles - October 30, 2007 - 21:41
Version:4.7.x-1.x-dev» 5.x-1.1
Category:bug report» feature request
Status:by design» active

I ran into the same problem with the mimemail module.

I know that it's "not returnpath's fault" but it would be nice if rather than a fatal error the module would do a check if the function_exists('user_mail_wrapper') before declaring it and if it exists, just do a drupal_set_message warning about the incompatibility. http://php.net/function_exists

Tentatively setting back to active as a feature request in light of this new proposal, but feel free to won't fix again if you feel this is unecessary.

#3

not_Dries_Buytaert - October 7, 2009 - 09:21
Title:Module interferes with smtp.module» Incompatible with smtp.module (redeclared function)
Version:5.x-1.1» 6.x-1.0
Category:feature request» bug report

Getting this error message after enabling returnpath.module (Return-Path), while smtp.module (SMTP Authentication Support) is enabled:
Fatal error: Cannot redeclare drupal_mail_wrapper() (previously declared in {path}/modules/smtp/smtp.module:236) in {path}/modules/returnpath/returnpath.module on line 52
using:
returnpath-6.x-1.0.tar.gz
smtp-6.x-1.0-beta3.tar.gz
PHPMailer_v5.0.0.tar.gz

I have also submitted this issue for the SMTP Authentication Support module:
http://drupal.org/node/597986

#4

not_Dries_Buytaert - October 7, 2009 - 10:39

It turns out (http://drupal.org/node/597986) that the SMTP Authentication Support module DOES correctly handle the return path email headers. Therefore, activation of the returnpath.module (Return-Path) should be disabled/ disallowed, whenever the 'SMTP Authentication Support' module is activated.

#5

budda - October 25, 2009 - 14:12

How do you disallow/disable a module if another module is active?

 
 

Drupal is a registered trademark of Dries Buytaert.