Hi,

I have following warnings after cron run:

# warning: Missing argument 2 for variable_get(), called in /var/www/mysite/sites/all/modules/bounced_email/bounced_email.module on line 290 and defined in /var/www/mysite/includes/bootstrap.inc on line 502.
# warning: imap_fetchheader() [function.imap-fetchheader]: Bad message number in /var/www/mysite/sites/all/modules/bounced_email/bounced_email.module on line 199.
# warning: imap_headerinfo() [function.imap-headerinfo]: Bad message number in /var/www/mysite/sites/all/modules/bounced_email/bounced_email.module on line 200.
# warning: imap_body() [function.imap-body]: Bad message number in /var/www/mysite/sites/all/modules/bounced_email/bounced_email.module on line 201.

I have following settings:

Connection Type: POP
Mailbox Host: pop.yandex.ru
Mailbox Port: 110/pop3
Extra commands:
Bounce Mailbox: email
Mailbox Username: usrname
Mailbox Password: password

I see it connects ok. It even tries to process first bounced email, cause I see it in "deleted" folder in my webmail after cron run.
But bounced_email_* tables is empty.

CommentFileSizeAuthor
#7 cron-warnings-770994-7.patch702 byteskevin.dutra

Comments

dealancer’s picture

I've found the source of warnings.

On line 289 you could see code

  if ($message_count > $configuration['bounce_max_process']) {
    $message_count = variable_get('bounce_max_process');
  }

1. $configuration is not declared, so $message_count is set to 100 in my case.
2. variable_get('bounce_max_process'); is not correct, so code should be replaced on this

  $configuration['bounce_max_process'] = variable_get('bounce_max_process', 100);
  if ($message_count > $configuration['bounce_max_process']) {
    $message_count =  $configuration['bounce_max_process'];
  }
dealancer’s picture

I've found one more issue.
It would be nice if you grant me access to the CVS.
Thanks.

robert castelo’s picture

Hi dealancer, please add patches to issues if you have code to fix bugs or add features.

Only include code for the particular bug/feature in each patch so that they are easy to review and commit.

http://drupal.org/patch

I'll look at this issue early next week.

robert castelo’s picture

Status: Active » Fixed

Thanks, fixed in 6.x-2.1.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

kevin.dutra’s picture

Version: 6.x-0.1 » 6.x-1.x-dev
Status: Closed (fixed) » Active

This still occurs. It will present itself anytime the number of messages exceeds the setting for maximum number to process.

  if ($message_count > $configuration['bounce_max_process']) {
    $message_count = variable_get('bounce_max_process');
  }

Also, FWIW, it's confusing that your Git dev branch is labeled 1.x when the current module version is 2.1.

kevin.dutra’s picture

Status: Active » Needs review
StatusFileSize
new702 bytes