Re: vdelivermail.c - dot-qmail processing, FreeBSD Port: vpopmail-5.4.26

2008-03-17 Thread Peter Pentchev
On Sat, Mar 15, 2008 at 02:56:24PM +0100, Michal Sviba wrote:
 Hi Tom,
 
 there are some #ifdef quotas, but not exactly in part witch I mean.
 
 When I've done #diff between vdelivermail.c 5.4.25 and .26, there are no
 differences.
 
 But I've luckily found/repair the problem :)))
 Problem was in variable DeleteEmail witch is set just one time (DelteEmail 
 = 1) and default is 0.
 
 So, I've tried this: vdelivermail.c:660
  655
  656 /* rewind the message */
  657 lseek(0,0L,SEEK_SET);
  658
  659 /* same env. for each line .qmail */
  660 DeleteMail = 0; // set default

Great catch!  I've just committed this patch to the FreeBSD port of
vpopmail - probably as a band-aid that will go away with 5.4.27, but
still quite important for the 5.4.26 users :)

Thanks for tracking this down!

G'luck,
Peter

-- 
Peter Pentchev  [EMAIL PROTECTED][EMAIL PROTECTED][EMAIL PROTECTED]
PGP key:http://people.FreeBSD.org/~roam/roam.key.asc
Key fingerprint FDBA FD79 C26F 3C51 C95E  DF9E ED18 B68D 1619 4553
This sentence is false.


pgpxQw6TJnD0P.pgp
Description: PGP signature


Re: vdelivermail.c - dot-qmail processing, FreeBSD Port: vpopmail-5.4.26

2008-03-15 Thread Michal Sviba

Hi Tom,

there are some #ifdef quotas, but not exactly in part witch I mean.

When I've done #diff between vdelivermail.c 5.4.25 and .26, there are no
differences.

But I've luckily found/repair the problem :)))
Problem was in variable DeleteEmail witch is set just one time 
(DelteEmail = 1) and default is 0.


So, I've tried this: vdelivermail.c:660
 655
 656 /* rewind the message */
 657 lseek(0,0L,SEEK_SET);
 658
 659 /* same env. for each line .qmail */
 660 DeleteMail = 0; // set default
 661
 662 /* This is an command */
 663 if ( *address == '|' ) {
 664

It's setting default value for each line in .qmail and for me it's 
working properly.


It is because of setting InHeaders=1 is default and can be changed only 
by int is_spam() and is_spam is called by int fdcopy() .


I'm not fluent in language C and someone should check this my patch


My environment is: FreeBSD 5.4, vpopmail 5.4.26 make -DWITH_MYSQL 
-DWITH_QMAIL_EXT -DWITH_SPAMASSASSIN -DSPAM_THRESHOLD=15

and freebsd-ports-patch was used.

Michal

Tom Collins napsal(a):

I think this is a known problem with 5.4.26, related to quotas.

Please downgrade to 5.4.25 until Rick can get 5.4.27 released.  He's 
taken over development of vpopmail.


-Tom

On Mar 13, 2008, at 3:42 PM, Michal Sviba wrote:


Hi Tom,

I'm a user/admin of vdelivermail.c (vpopmail+qmail). I've used 
vpopmail 5.4.10 for many years and 10days ago I've decided to build 
the new one (5.4.26).


It mostly work fine, but in new version is different behaviour in 
processing .qmail


:: version 5.4.10 .qmail
[EMAIL PROTECTED]
/usr/local/vpopmail/domains/domain.tld/...

It send a copy of mail to [EMAIL PROTECTED], than store a copy to 
Maildir. It is expected processing form many years (for me).





:: version 5.4.26 .qmail
[EMAIL PROTECTED]
/usr/local/vpopmail/domains/domain.tld/...

It send a copy of mail to [EMAIL PROTECTED], than finish. Without 
storing a copy to Maildir.




:: version 5.4.26 .qmail
/usr/local/vpopmail/domains/domain.tld/...
[EMAIL PROTECTED]

Store a copy, than forward email to address.






So, I can re-sed every .qmail file ... :) but it's bad idea (because 
of clean system and QmailAdmin).



Probably is bug in vdelivermail.c:void deliver_mail(char *address, 
char *quota). Because after processing [EMAIL PROTECTED] 
.qmail-line vexiterr() is called. vexiterr() will call vexit() than 
vexit() call exit() = code is finishing.


In version 5.4.10 was never called *exit* in this part of code (lines 
569-608).



Best regards,
Michal

--
 Hi! I'm a .signature virus! Copy me into your ~/.signature to help me
spread!


-Tom





--
  Hi! I'm a .signature virus! Copy me into your ~/.signature to help me
spread!


smime.p7s
Description: S/MIME Cryptographic Signature