Download & Extend

Incompatible with smtp.module (redeclared function)

Project:Return-Path
Version:6.x-1.x-dev
Component:Code
Category:bug report
Priority:normal
Assigned:budda
Status:active

Issue Summary

[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

Comments

#1

Status:active» closed (works as designed)

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

#2

Version:4.7.x-1.x-dev» 5.x-1.1
Category:bug report» feature request
Status:closed (works as designed)» 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

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

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

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

#6

Hi, I am getting this error when trying to uninstall the module, how can I get it to uninstall successfully?

#7

Version:6.x-1.0» 6.x-1.x-dev
Assigned to:Anonymous» budda

I've added the function_exists check as per #973730: Cannot redeclare drupal_mail_wrapper()

Adding a message saying return-path is disabled due to another module still to be done.