diff -ru logrotate-3.3-orig/logrotate.c logrotate-3.3-andrew/logrotate.c --- logrotate-3.3-orig/logrotate.c Wed Jun 16 16:37:19 1999 +++ logrotate-3.3-andrew/logrotate.c Tue Aug 1 15:06:10 2000 @@ -497,11 +497,14 @@ command = alloca(strlen(mailFilename) + 100 + strlen(UNCOMPRESS_PIPE)); - if (log->flags & LOG_FLAG_COMPRESS) - sprintf(command, "%s < %s | %s '%s' %s", - UNCOMPRESS_PIPE, mailFilename, mailCommand, + if (log->flags & LOG_FLAG_COMPRESS) { + sprintf(command, "%s %s `echo \"%s\" | %s \"s/.*\\///\"` | %s '%s' %s", + UUENCODE_PIPE, mailFilename, mailFilename, SED_PIPE, + mailCommand, log->files[logNum], log->logAddress); + printf("%s \n", command); + } else sprintf(command, "%s '%s' %s < %s", mailCommand, mailFilename, log->logAddress, mailFilename); diff -ru logrotate-3.3-orig/logrotate.h logrotate-3.3-andrew/logrotate.h --- logrotate-3.3-orig/logrotate.h Wed Jun 16 16:08:06 1999 +++ logrotate-3.3-andrew/logrotate.h Tue Aug 1 14:58:39 2000 @@ -16,6 +16,8 @@ #define COMPRESS_COMMAND "gzip -9" #define COMPRESS_EXT ".gz" #define UNCOMPRESS_PIPE "gunzip" +#define UUENCODE_PIPE "uuencode" +#define SED_PIPE "sed" #define NO_FORCE_ROTATE 0 #define FORCE_ROTATE 1