]>
git.ipfire.org Git - thirdparty/mlmmj.git/log
mortenp [Sat, 19 Jun 2004 03:48:23 +0000 (13:48 +1000)]
make sure we use the wrappers
mortenp [Sat, 19 Jun 2004 03:47:58 +0000 (13:47 +1000)]
changed to use the new memory wrappers
(my caffeine free week is officially over!)
mortenp [Sat, 19 Jun 2004 03:44:47 +0000 (13:44 +1000)]
changed to use the new memory wrappers
(my caffeine free week is officially over!)
mortenp [Sat, 19 Jun 2004 03:36:08 +0000 (13:36 +1000)]
added memory.c to all targets
mortenp [Sat, 19 Jun 2004 03:35:38 +0000 (13:35 +1000)]
initial revision
mortenp [Sat, 19 Jun 2004 02:04:53 +0000 (12:04 +1000)]
removed dead code
mortenp [Sat, 19 Jun 2004 01:36:37 +0000 (11:36 +1000)]
removed dead code
mortenp [Sat, 19 Jun 2004 01:08:51 +0000 (11:08 +1000)]
removed unused variable
mortenp [Sat, 19 Jun 2004 00:54:54 +0000 (10:54 +1000)]
added debugging (export MLMMJ_TESTING to use dummy smtpd)
mmj [Fri, 18 Jun 2004 04:03:50 +0000 (14:03 +1000)]
Get the free()'s in the right spot
mmj [Thu, 17 Jun 2004 22:39:49 +0000 (08:39 +1000)]
I bet these are the last ones missing. At least the mlmmj-maintd could run for months and months before gain 100k
mmj [Thu, 17 Jun 2004 19:06:04 +0000 (05:06 +1000)]
Forgot to update README
mmj [Thu, 17 Jun 2004 19:03:45 +0000 (05:03 +1000)]
Add TODO item
mmj [Thu, 17 Jun 2004 19:01:17 +0000 (05:01 +1000)]
Forgot something
mmj [Thu, 17 Jun 2004 19:00:42 +0000 (05:00 +1000)]
Implement control/delheaders in where one can specify all the headers
to delete in incoming mail to the list.
mmj [Thu, 17 Jun 2004 19:00:28 +0000 (05:00 +1000)]
struct strlist;
mmj [Thu, 17 Jun 2004 19:00:21 +0000 (05:00 +1000)]
0.7.3
mmj [Thu, 17 Jun 2004 18:59:25 +0000 (04:59 +1000)]
Add function that reads several lines of a control file and return
a struct with the count of lines, and an array with them.
Last item is NULL.
mmj [Thu, 17 Jun 2004 12:49:18 +0000 (22:49 +1000)]
correct Changelog
mmj [Thu, 17 Jun 2004 12:48:34 +0000 (22:48 +1000)]
Make it possible to specify several owner emailaddresses, not just one
mmj [Wed, 16 Jun 2004 22:10:29 +0000 (08:10 +1000)]
+owner functionality
mmj [Wed, 16 Jun 2004 21:12:15 +0000 (07:12 +1000)]
It's not 0.7.3 yet
mmj [Wed, 16 Jun 2004 21:11:55 +0000 (07:11 +1000)]
Goodbye GPL license, Welcome MIT
mmj [Mon, 14 Jun 2004 15:12:43 +0000 (01:12 +1000)]
THanks to the FreeBSD guy
mmj [Mon, 14 Jun 2004 15:06:37 +0000 (01:06 +1000)]
Mention it's 0.7.2 in the ChangeLog
mmj [Mon, 14 Jun 2004 15:01:43 +0000 (01:01 +1000)]
*** empty log message ***
mmj [Mon, 14 Jun 2004 14:56:47 +0000 (00:56 +1000)]
Add functionality for subscribers only posting and to only allow posts with
listaddress in To: or Cc:
mmj [Mon, 14 Jun 2004 14:55:58 +0000 (00:55 +1000)]
Fix typo in notintocc and add subscribers only post text
mmj [Mon, 14 Jun 2004 14:54:52 +0000 (00:54 +1000)]
Mention control/tocc and control/subonlypost in TUNABLES and ChangeLog
Bump version to 0.7.2
mmj [Mon, 14 Jun 2004 11:57:46 +0000 (21:57 +1000)]
Make mlmmj-sub change uid to the listdir owner
mmj [Mon, 14 Jun 2004 11:57:23 +0000 (21:57 +1000)]
Reflect latest change to mlmmj-sub
mmj [Fri, 11 Jun 2004 10:26:58 +0000 (20:26 +1000)]
More memory debugging, and small bugfixes
mmj [Thu, 10 Jun 2004 17:51:33 +0000 (03:51 +1000)]
*** empty log message ***
mmj [Thu, 10 Jun 2004 16:11:55 +0000 (02:11 +1000)]
RCPT TO -> .reciptto, MAIL FROM -> .mailfrom, not the other way around
mmj [Thu, 10 Jun 2004 13:15:49 +0000 (23:15 +1000)]
Missing closedir added
mmj [Thu, 10 Jun 2004 12:11:09 +0000 (22:11 +1000)]
remove stderr debug info
mmj [Thu, 10 Jun 2004 05:52:59 +0000 (15:52 +1000)]
Add some free()'s and fix bug with the maintd logfile
mmj [Thu, 10 Jun 2004 05:52:46 +0000 (15:52 +1000)]
Updates
mmj [Wed, 9 Jun 2004 11:42:54 +0000 (21:42 +1000)]
Furhter README updates
mmj [Wed, 9 Jun 2004 11:24:56 +0000 (21:24 +1000)]
Add a macro to make sure mlmmj binaries are invoked with full path
mmj [Wed, 9 Jun 2004 11:24:43 +0000 (21:24 +1000)]
Add the function to mlmmj-maintd to unsubscribe people who've been bouncing
for BOUNCELIFE (default 432000 sec, 5 days) time. This completes
the bouncehandling of mlmmj. SIC!
mmj [Wed, 9 Jun 2004 11:23:59 +0000 (21:23 +1000)]
Updated to reflect it's 0.7.0 time
mmj [Wed, 9 Jun 2004 09:08:32 +0000 (19:08 +1000)]
Fix some directory leaks which could cause corruption, and dont leak the
bounce probe answer in the queue.
mmj [Wed, 9 Jun 2004 09:07:59 +0000 (19:07 +1000)]
Fix some directory leaks which could cause corruption.
mmj [Wed, 9 Jun 2004 09:07:38 +0000 (19:07 +1000)]
Add ChangeLog entry and mention in README that mlmmj-maintd might still
be a bit unstable.
mmj [Tue, 8 Jun 2004 23:12:29 +0000 (09:12 +1000)]
probe_bounces now implemented and a bit of logging
mmj [Tue, 8 Jun 2004 23:12:09 +0000 (09:12 +1000)]
Header file changes
mmj [Tue, 8 Jun 2004 20:23:50 +0000 (06:23 +1000)]
mlmmj-maintd work
mmj [Tue, 8 Jun 2004 14:15:05 +0000 (00:15 +1000)]
Handle bouncing bounce probes
mmj [Tue, 8 Jun 2004 13:37:15 +0000 (23:37 +1000)]
text update
mmj [Tue, 8 Jun 2004 10:18:30 +0000 (20:18 +1000)]
Change the text a bit.
mmj [Tue, 8 Jun 2004 10:18:22 +0000 (20:18 +1000)]
Update
mmj [Tue, 8 Jun 2004 10:17:16 +0000 (20:17 +1000)]
openrandexclrw added
mmj [Tue, 8 Jun 2004 10:17:04 +0000 (20:17 +1000)]
New function
mmj [Tue, 8 Jun 2004 10:15:27 +0000 (20:15 +1000)]
Bounce probes done. Review appreciated.
mmj [Mon, 7 Jun 2004 18:09:22 +0000 (04:09 +1000)]
Sorry I broke CVS, I'll fix ASAP. It was a commit by mistake.
mmj [Mon, 7 Jun 2004 17:55:56 +0000 (03:55 +1000)]
Plug memory leak in mlmmj-send
mmj [Mon, 7 Jun 2004 13:54:49 +0000 (23:54 +1000)]
Add GPL header
mmj [Mon, 7 Jun 2004 12:36:39 +0000 (22:36 +1000)]
New function to prepare a standard mail in an easy way, and make send_help
use it. More to follow :)
mmj [Mon, 7 Jun 2004 12:36:23 +0000 (22:36 +1000)]
New function to prepare a standard mail in an easy way.
mmj [Mon, 7 Jun 2004 12:35:58 +0000 (22:35 +1000)]
Comment out myfgetline since it's not used at all anymore
mortenp [Mon, 7 Jun 2004 11:24:32 +0000 (21:24 +1000)]
primitive implementation of probe (-p option)
mmj [Sun, 6 Jun 2004 21:57:40 +0000 (07:57 +1000)]
Prep for 0.6.0 and small debug info removal etc.
mmj [Sun, 6 Jun 2004 21:08:09 +0000 (07:08 +1000)]
Assorted bugfixes.
Addition of lots of unlink() in listcontrol.c
Make random-str return an even more random str, and hex format it
since it looks better :)
mmj [Sun, 6 Jun 2004 18:29:13 +0000 (04:29 +1000)]
getlistaddr was tought that listaddress moved to control/listaddress
mlmmj-maintd is no longer cleaning moderation/queue, now that dir is gone
mlmmj-make-ml.sh now doesn't make moderation/queue
mlmmj-process now uses queue for outgoing moderator mail, not modetaion/queue
mmj [Sun, 6 Jun 2004 18:27:25 +0000 (04:27 +1000)]
Some updates
mmj [Sun, 6 Jun 2004 16:52:23 +0000 (02:52 +1000)]
Cleanup printf()'s and errorhandling
mmj [Sun, 6 Jun 2004 16:42:34 +0000 (02:42 +1000)]
Remove fprintf(stderr, "%s", smtpreply) from checkwait_smtpreply. No need to
call fprintf for every reply from the mailserver.
mmj [Sun, 6 Jun 2004 16:38:14 +0000 (02:38 +1000)]
Last place to get rid of FILE* are now done.
mmj [Sun, 6 Jun 2004 15:02:28 +0000 (01:02 +1000)]
mlmmj-sub is now FILE* clean
mmj [Sat, 5 Jun 2004 20:27:14 +0000 (06:27 +1000)]
Use mmap to find the subscribers in the subscribers files
mmj [Sat, 5 Jun 2004 14:55:25 +0000 (00:55 +1000)]
Use MAP_FAILED to indicate failed mmap rather than (void \*)-1
mmj [Sat, 5 Jun 2004 13:49:27 +0000 (23:49 +1000)]
Latest mlmmj-send change ChangeLog entry
mmj [Sat, 5 Jun 2004 13:49:11 +0000 (23:49 +1000)]
Instead of reading 1 line at a time in mlmmj-send everytime we send the
mail, mmap it once, and pass the pointer to the send function which
writes one line at a time with proper \n -> \r\n and '.' -> '..'
conversion.
mmj [Sat, 5 Jun 2004 13:48:07 +0000 (23:48 +1000)]
New mlmmj-send takes a char * and the size of the mail to send instead
of the mail file descriptor.
mmj [Fri, 4 Jun 2004 10:46:33 +0000 (20:46 +1000)]
Another FILE* bites the dust
mmj [Fri, 4 Jun 2004 10:41:57 +0000 (20:41 +1000)]
Bye bye FILE*, welcome fd
mmj [Thu, 3 Jun 2004 16:58:22 +0000 (02:58 +1000)]
fileno(stdin) instead of FILENO_STDIN
mmj [Thu, 3 Jun 2004 16:57:14 +0000 (02:57 +1000)]
Bye bye FILE*
mmj [Thu, 3 Jun 2004 16:45:46 +0000 (02:45 +1000)]
Goodbye FILE*
mmj [Thu, 3 Jun 2004 15:11:00 +0000 (01:11 +1000)]
write_mailbody_from_file is now write_mailbody_from_fd
mmj [Thu, 3 Jun 2004 14:50:02 +0000 (00:50 +1000)]
header_token was not used anymore for a long time, so get rid of it
mmj [Thu, 3 Jun 2004 14:48:00 +0000 (00:48 +1000)]
-#include <stdio.h>
mmj [Thu, 3 Jun 2004 14:39:01 +0000 (00:39 +1000)]
-#include <stdio.h>
mmj [Thu, 3 Jun 2004 14:30:09 +0000 (00:30 +1000)]
Lets get rid of stdio shall we :-)
mmj [Thu, 3 Jun 2004 14:29:59 +0000 (00:29 +1000)]
Headerfile sync. I forgot some earlier, sorry :\
mmj [Thu, 3 Jun 2004 13:56:45 +0000 (23:56 +1000)]
Bye bye FILE * and welcome fd's
mmj [Thu, 3 Jun 2004 10:45:33 +0000 (20:45 +1000)]
FILE* is now fd
mmj [Thu, 3 Jun 2004 06:36:20 +0000 (16:36 +1000)]
Make listcontrol get the mailname for mlmmj-bounce
mmj [Thu, 3 Jun 2004 06:34:36 +0000 (16:34 +1000)]
3 things:
· Check that bouncefile is not a symlink (TODO)
· When everything went ok, return EXIT_SUCCES not EXIT_FAILURE
· If there's a bouncemail, save it as bfilename.lastmsg
And in more readable form:
--- mlmmj-bounce.c 26 May 2004 23:25:57 -0000 1.7
+++ mlmmj-bounce.c 3 Jun 2004 06:30:39 -0000
@@ -37,16 +37,16 @@
int main(int argc, char **argv)
{
- int opt;
+ int opt, fd;
char *listdir = NULL, *address = NULL, *number = NULL;
- char *bfilename, *a, *buf;
+ char *mailname = NULL, *savename, *bfilename, *a, *buf;
size_t len;
- int fd;
time_t t;
+ struct stat st;
log_set_name(argv[0]);
- while ((opt = getopt(argc, argv, "hVL:a:n:")) != -1) {
+ while ((opt = getopt(argc, argv, "hVL:a:n:m:")) != -1) {
switch(opt) {
case 'L':
listdir = optarg;
@@ -54,6 +54,9 @@
case 'a':
address = optarg;
break;
+ case 'm':
+ mailname = optarg;
+ break;
case 'n':
number = optarg;
break;
@@ -109,7 +112,14 @@
exit(EXIT_SUCCESS); /* Not subbed, so exit silently */
}
- /* TODO make sure the file we open below is not a symlink */
+ if(lstat(bfilename, &st) == 0) {
+ if((st.st_mode & S_IFLNK) == S_IFLNK) {
+ log_error(LOG_ARGS, "%s is a symbolic link",
+ bfilename);
+ exit(EXIT_FAILURE);
+ }
+ }
+
if ((fd = open(bfilename, O_WRONLY|O_APPEND|O_CREAT,
S_IRUSR|S_IWUSR)) < 0) {
log_error(LOG_ARGS, "Could not open '%s'", bfilename);
@@ -136,5 +146,11 @@
writen(fd, buf, strlen(buf));
close(fd);
- return EXIT_FAILURE;
+ if(mailname) {
+ savename = concatstr(2, bfilename, ".lastmsg");
+ rename(mailname, savename);
+ free(savename);
+ }
+
+ return EXIT_SUCCESS;
}
mmj [Wed, 2 Jun 2004 22:57:45 +0000 (08:57 +1000)]
mlmmj-recieve deFILEified
mmj [Wed, 2 Jun 2004 22:47:20 +0000 (08:47 +1000)]
dumpfd2fd
mortenp [Wed, 2 Jun 2004 21:57:30 +0000 (07:57 +1000)]
"Resolving" the conflict by committing my version anyway (it has a nice comment). That guy is fast.
mmj [Wed, 2 Jun 2004 21:52:48 +0000 (07:52 +1000)]
Simply close socket if error in transmission
mmj [Wed, 2 Jun 2004 21:50:40 +0000 (07:50 +1000)]
mygetline EINTR handling and errno = 0
mortenp [Wed, 2 Jun 2004 21:34:32 +0000 (07:34 +1000)]
fixed fgets() loop
mmj [Wed, 2 Jun 2004 19:27:20 +0000 (05:27 +1000)]
--- src/mlmmj-send.c 2 Jun 2004 19:10:11 -0000 1.31
+++ src/mlmmj-send.c 2 Jun 2004 19:19:48 -0000
@@ -35,8 +35,6 @@
#include "log_error.h"
#include "mygetline.h"
-static int conncount = 0; /* Connection count */
-
char *bounce_from_adr(const char *recipient, const char *listadr,
const char *mailfilename)
{
@@ -345,15 +343,6 @@
return 0;
}
-void sig_child(int sig)
-{
- pid_t pid;
- int stat;
-
- while((pid = waitpid(-1, &stat, WNOHANG) > 0))
- conncount--;
-}
-
static void print_help(const char *prg)
{
printf("Usage: %s [-L /path/to/list || -l listctrl] -m /path/to/mail "
@@ -380,7 +369,7 @@
{
size_t len = 0;
int sockfd = 0, opt, mindex;
- int deletewhensent = 1, *newsockfd, sendres, archive = 1;
+ int deletewhensent = 1, sendres, archive = 1;
char *listaddr, *mailfilename = NULL, *subfilename = NULL;
char *replyto = NULL, *bounceaddr = NULL, *to_addr = NULL;
char *relayhost = NULL, *archivefilename = NULL, *tmpstr;
@@ -389,8 +378,6 @@
DIR *subddir;
FILE *subfile = NULL, *mailfile = NULL, *tmpfile;
struct dirent *dp;
- pid_t childpid;
- struct sigaction sigact;
log_set_name(argv[0]);
@@ -564,11 +551,6 @@
}
free(subddirname);
- sigact.sa_handler = sig_child;
- sigemptyset(&sigact.sa_mask);
- sigact.sa_flags = SA_NOCLDSTOP;
- sigaction(SIGCHLD, &sigact, 0);
-
while((dp = readdir(subddir)) != NULL) {
if(!strcmp(dp->d_name, "."))
continue;
@@ -585,41 +567,19 @@
fprintf(stderr, "found subfile '%s'\n", subfilename);
free(subfilename);
- while((conncount >= MAX_CONNECTIONS))
- usleep(WAITSLEEP);
-
- childpid = fork();
- if(childpid < 0)
- log_error(LOG_ARGS, "Could not fork.");
- /* TODO: we have to keep track of unsent
- * files */
-
- conncount++;
-
- if(childpid == 0) {
- newsockfd = malloc(sizeof(int));
- initsmtp(newsockfd, relayhost);
- send_mail_many(*newsockfd, NULL, NULL,
- mailfile, subfile, listaddr,
- archivefilename, listdir,
- mlmmjbounce);
- endsmtp(newsockfd);
- free(newsockfd);
- fclose(subfile);
- exit(EXIT_SUCCESS);
- } else
- fclose(subfile);
+ initsmtp(&sockfd, relayhost);
+ send_mail_many(sockfd, NULL, NULL, mailfile, subfile,
+ listaddr, archivefilename, listdir,
+ mlmmjbounce);
+ endsmtp(&sockfd);
+ fclose(subfile);
}
closedir(subddir);
break;
}
- while(conncount > 0)
- usleep(WAITSLEEP);
-
if(archive) {
rename(mailfilename, archivefilename);
-
free(archivefilename);
} else if(deletewhensent)
unlink(mailfilename);
mmj [Wed, 2 Jun 2004 19:26:35 +0000 (05:26 +1000)]
No need for several connections tuning for mlmmj-send
mmj [Wed, 2 Jun 2004 19:26:19 +0000 (05:26 +1000)]
Changelog update
mmj [Wed, 2 Jun 2004 19:16:11 +0000 (05:16 +1000)]
ChangeLog update