Hi:

There is no install file with this module, at least for 5.x) which means that there is no uninstall function for it, either. Therefore, after the smtp module is installed it sets itself as the 'smtp_library' within drupal's variables. When drupal_mail() gets called it checks whether smtp_library is set (http://api.drupal.org/api/function/drupal_mail/5) before sending mail. If so, it sends the mail data off to whatever module is set in that var (s:34:"sites/all/modules/smtp/smtp.module"; in our case).

If the module is disabled, there is no cleanup of this variable and drupal_mail, therefore, still attempts to send mail out through path/to/smtp/smtp.module even though it's not enabled. This effectively breaks outgoing mail from the system.

Please let me know if you have any questions, comments.

Thanks!

Ian

Comments

oadaeh’s picture

Priority: Critical » Normal

Yes, I know about this issue. My plan is to back port most of the changes I've done in the 6.x branch (which includes adding the .install file), but I'm waiting until I feel I have a fairly stable, bug free release, so I'm not back porting the bugs as well.

EDIT:
Oh, and you should turn the module off on the settings page before disabling it. That should fix your problem of it being called when it's disabled.

And even with an .install file present, disabling the module is not enough to cleanup of that variable. You have to uninstall the module in order to have it's hook_uninstall() function called.

I'll be adding an .install file soon.

wundo’s picture

Issue summary: View changes
Status: Active » Closed (works as designed)