Hey,
So I whipped up a little wrapper program around read_header() and makemd5()
that crashes on the Opteron server at SourceForge, but works properly on my
Pentium.
Just one problem: what tools can I use to debug this thing on Opteron!?
I've attached my test program. It compiles in the dbmail build tree, like so:
gcc -g -O -I. -o testmd5 testmd5.c header.o dbmd5.o md5.o debug.o
Aaron
/*
Copyright (C) 1999-2003 IC & S [EMAIL PROTECTED]
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later
version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
/* $Id: main.c,v 1.46 2004/03/04 11:13:24 aaron Exp $
* (c) 2000-2002 IC&S, The Netherlands
*
* main file for dbmail-smtp */
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include "dbmail.h"
#include "dbmd5.h"
#include "main.h"
#include "pipe.h"
#include "list.h"
#include "auth.h"
#include "header.h"
#include "dsn.h"
#include <string.h>
#include <stdlib.h>
/* For getopt() */
#include <unistd.h>
/* For exit codes */
#include <sysexits.h>
#define MESSAGEIDSIZE 100
#define NORMAL_DELIVERY 1
#define SPECIAL_DELIVERY 2
#define INDEX_DELIVERY_MODE 1
/* syslog */
#define PNAME "dbmail/smtp"
char *header = NULL;
char *deliver_to_header = NULL;
char *deliver_to_mailbox = NULL;
u64_t headersize, headerrfcsize;
int main(int argc, char *argv[])
{
char *header, *md5;
u64_t headerrfcsize = 0, headersize = 0;
if (!read_header(stdin, &headerrfcsize, &headersize, &header))
return 1;
md5 = makemd5(header);
printf("%s\n", md5);
return 0;
}