View | Details | Raw Unified | Return to bug 106818
Collapse All | Expand All

(-)../metamail.new/files/patch-aa (-2 / +4 lines)
Lines 1-5 Link Here
1
*** Makefile.orig      Wed Jan 26 12:32:33 1994
1
diff -rc ./Makefile /usr/ports/mail/metamail/work/mm2.7/src/Makefile
2
--- Makefile   Wed Jan 19 18:53:05 2000
2
*** ./Makefile	Wed Jan 26 18:32:33 1994
3
--- /usr/ports/mail/metamail/work/mm2.7/src/Makefile	Sat Dec 16 22:21:45 2006
3
***************
4
***************
4
*** 26,32 ****
5
*** 26,32 ****
5
  CP = cp
6
  CP = cp
Lines 126-128 Link Here
126
  
127
  
127
  uninstall-all:
128
  uninstall-all:
128
  	@(cd bin; 				\
129
  	@(cd bin; 				\
130
Only in /usr/ports/mail/metamail/work/mm2.7/src/: Makefile.orig
(-)../metamail.new/files/patch-ab (-30 / +98 lines)
Lines 1-33 Link Here
1
*** config.h.orig	Mon Oct 17 21:06:22 1994
1
diff -rc ./bin/showaudio /usr/ports/mail/metamail/work/mm2.7/src/bin/showaudio
2
--- config.h	Mon Oct 17 21:08:13 1994
2
*** ./bin/showaudio	Thu Feb  3 00:21:26 1994
3
--- /usr/ports/mail/metamail/work/mm2.7/src/bin/showaudio	Sat Dec 16 22:21:45 2006
3
***************
4
***************
4
*** 73,79 ****
5
*** 15,23 ****
5
  #ifdef SYSV
6
  # WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES.
6
  #define RESET_PROGRAM "tput clear"
7
  #
7
  #else
8
  
8
! #ifdef __BSD_4_4__
9
! 
9
  #define RESET_PROGRAM "/usr/bin/reset"
10
  if (! $?METAMAIL_TMPDIR) then
10
  #else
11
!     set METAMAIL_TMPDIR=/tmp
11
  #define RESET_PROGRAM "/usr/ucb/reset"
12
  endif
12
--- 73,79 ----
13
  
13
  #ifdef SYSV
14
  # First, figure out which machine to play it on!
14
  #define RESET_PROGRAM "tput clear"
15
--- 15,49 ----
15
  #else
16
  # WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES.
16
! #if defined(__BSD_4_4__) || defined(__FreeBSD__)
17
  #
17
  #define RESET_PROGRAM "/usr/bin/reset"
18
  
18
  #else
19
! # Set a sensible value for the temporary directory, if its not
19
  #define RESET_PROGRAM "/usr/ucb/reset"
20
! # already set.  If TMPDIR is set previously, then we will
21
! # assume it is adequately protected.
22
  if (! $?METAMAIL_TMPDIR) then
23
!     if ($?TMPDIR) then
24
!         set METAMAIL_TMPDIR="$TMPDIR"
25
!     else
26
!         set METAMAIL_TMPDIR=~/metamail_tmp
27
!     endif
28
! endif
29
! 
30
! # Set a sensible umask value
31
! umask 077
32
! 
33
! # Make sure that the temporary directory is available
34
! if (! -d "$METAMAIL_TMPDIR") then
35
! 
36
!     if (! -e "$METAMAIL_TMPDIR") then
37
!         mkdir "$METAMAIL_TMPDIR"
38
!     else
39
!         echo "$METAMAIL_TMPDIR exists, but is not a directory"
40
!         exit 2
41
!     endif
42
! 
43
!     if ( $status != 0 || ! -d "$METAMAIL_TMPDIR" ) then
44
!         echo "Error creating $METAMAIL_TMPDIR"
45
!         exit 2
46
!     endif
47
! 
48
  endif
49
  
50
  # First, figure out which machine to play it on!
20
***************
51
***************
21
*** 155,161 ****
52
*** 33,39 ****
22
--- 155,165 ----
53
  set ORG="Bellcore"
23
  #ifdef NeXT
54
  set STDINPUT=0
24
  #define sigtype void
55
  if ("$1" == "-p") then
25
  #else
56
!     set AUDIOPHONE=$2
26
+ #ifdef __FreeBSD__
57
      shift
27
+ #define sigtype void
58
      shift
28
+ #else
59
  endif
29
  #define sigtype int
60
--- 59,65 ----
30
+ #endif
61
  set ORG="Bellcore"
31
  #endif
62
  set STDINPUT=0
32
  #endif
63
  if ("$1" == "-p") then
64
!     set AUDIOPHONE="$2"
65
      shift
66
      shift
67
  endif
68
***************
69
*** 173,179 ****
70
  	    set AUDIOPHONE=$<
71
  	endif
72
  	if ($thishost == $AUDIOPHONEHOST || $thishost == $AUDIOPHONEHOSTLONG) then
73
! 	    echo Calling Phone number $AUDIOPHONE
74
  	    echo "You MUST SAY HELLO when you answer the phone, or you will not hear the message."
75
  	    mail -s "showaudio: `whoami` called $AUDIOPHONE" $AUDIOLOGMAIL < /dev/null
76
  	    if ($STDINPUT) then
77
--- 199,205 ----
78
  	    set AUDIOPHONE=$<
79
  	endif
80
  	if ($thishost == $AUDIOPHONEHOST || $thishost == $AUDIOPHONEHOSTLONG) then
81
! 	    echo Calling Phone number "$AUDIOPHONE"
82
  	    echo "You MUST SAY HELLO when you answer the phone, or you will not hear the message."
83
  	    mail -s "showaudio: `whoami` called $AUDIOPHONE" $AUDIOLOGMAIL < /dev/null
84
  	    if ($STDINPUT) then
85
***************
86
*** 206,212 ****
87
      echo -n "File name:"
88
      set fname=$<
89
  endif
90
! cp $1 $fname
91
  if ($status == 0) echo Wrote raw audio file: $fname
92
  exit 0
93
  
94
--- 232,238 ----
95
      echo -n "File name:"
96
      set fname=$<
97
  endif
98
! cp "$1" $fname
99
  if ($status == 0) echo Wrote raw audio file: $fname
100
  exit 0
33
  
101
  
(-)../metamail.new/files/patch-ac (-16 / +57 lines)
Lines 1-19 Link Here
1
*** bin/sun2mime.ORIG	Sat Nov 13 15:53:51 1993
1
diff -rc ./bin/showexternal /usr/ports/mail/metamail/work/mm2.7/src/bin/showexternal
2
--- bin/sun2mime	Mon Dec 12 10:07:44 1994
2
*** ./bin/showexternal	Tue Feb  8 17:39:05 1994
3
--- /usr/ports/mail/metamail/work/mm2.7/src/bin/showexternal	Sat Dec 16 22:21:45 2006
3
***************
4
***************
4
*** 11,17 ****
5
*** 15,23 ****
5
  fi
6
  # WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES.
6
  TMPFILE=${METAMAIL_TMPDIR}/suntomime.$$
7
  # 
7
  
8
  
8
! /bin/nawk '
9
  onintr cleanup
9
    BEGIN { printf("Content-type: multipart/mixed; boundary=--------\n\n")
10
  if (! $?METAMAIL_TMPDIR) then
10
            RS=""; FS="\n"; mode="HEADER" }
11
!     set METAMAIL_TMPDIR=/tmp
11
    mode == "HEADER" {
12
  endif
12
--- 11,17 ----
13
  if (! $?FTP) then
13
  fi
14
      set FTP=ftp
14
  TMPFILE=${METAMAIL_TMPDIR}/suntomime.$$
15
--- 15,59 ----
16
  # WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES.
17
  # 
15
  
18
  
16
! /usr/bin/awk '
19
+ # Check argument integrity. Don't trust mail headers
17
    BEGIN { printf("Content-type: multipart/mixed; boundary=--------\n\n")
20
+ switch ("$1$2$3$4$5$6$7")
18
            RS=""; FS="\n"; mode="HEADER" }
21
+ case "*[\t ]*":
19
    mode == "HEADER" {
22
+   echo "Illegal white space in arguments\!"
23
+   echo "Command was:"
24
+   echo "'$0' '$1' '$2' '$3' '$4' '$5' '$6' '$7'"
25
+   exit 2
26
+ endsw
27
+ 
28
  onintr cleanup
29
+ # Set a sensible value for the temporary directory, if its not
30
+ # already set.  If TMPDIR is set previously, then we will
31
+ # assume it is adequately protected.
32
  if (! $?METAMAIL_TMPDIR) then
33
!     if ($?TMPDIR) then
34
!         set METAMAIL_TMPDIR="$TMPDIR"
35
!     else
36
!         set METAMAIL_TMPDIR=~/metamail_tmp
37
!     endif
38
! endif
39
! 
40
! # Set a sensible umask value
41
! umask 077
42
! 
43
! # Make sure that the temporary directory is available
44
! if (! -d "$METAMAIL_TMPDIR") then
45
! 
46
!     if (! -e "$METAMAIL_TMPDIR") then
47
!         mkdir "$METAMAIL_TMPDIR"
48
!     else
49
!         echo "$METAMAIL_TMPDIR exists, but is not a directory"
50
!         exit 2
51
!     endif
52
! 
53
!     if ( $status != 0 || ! -d "$METAMAIL_TMPDIR" ) then
54
!         echo "Error creating $METAMAIL_TMPDIR"
55
!         exit 2
56
!     endif
57
! 
58
  endif
59
  if (! $?FTP) then
60
      set FTP=ftp
(-)../metamail.new/files/patch-ad (-32 / +107 lines)
Lines 1-35 Link Here
1
*** fonts/Makefile.orig	Mon May 31 22:49:27 1993
1
diff -rc ./bin/showpartial /usr/ports/mail/metamail/work/mm2.7/src/bin/showpartial
2
--- fonts/Makefile	Thu May 18 21:55:42 1995
2
*** ./bin/showpartial	Thu Feb  3 00:21:29 1994
3
--- /usr/ports/mail/metamail/work/mm2.7/src/bin/showpartial	Sat Dec 16 22:21:45 2006
3
***************
4
***************
4
*** 28,39 ****
5
*** 2,9 ****
5
  	-${DIRBUILDER}
6
  # (The "-fb" might need to be changed to "-f" on some systems)
6
  
7
  #
7
  shownonascii: Xshownonascii
8
  
8
! 	sed -e s@/u/nsb/lib/fonts@`pwd`@ < Xshownonascii > shownonascii
9
  if (! $?METAMAIL_TMPDIR) then
9
  	chmod +x shownonascii
10
!     set METAMAIL_TMPDIR=/tmp
10
  
11
  endif
11
  mailto-hebrew: Xmailto-hebrew
12
  
12
! 	sed -e s@/u/nsb/lib/fonts@`pwd`@ < Xmailto-hebrew > mailto-hebrew
13
  set TREEROOT=${METAMAIL_TMPDIR}/m-prts-`whoami`
13
  	chmod +x mailto-hebrew
14
--- 2,45 ----
14
  
15
  # (The "-fb" might need to be changed to "-f" on some systems)
15
  clean:
16
  #
16
  	rm -f heb6x13.${FONTSUFFIX} heb8x13.${FONTSUFFIX} heb8x13B.${FONTSUFFIX}  shownonascii mailto-hebrew fonts.dir
17
  
17
--- 28,45 ----
18
+ # Check argument integrity. Don't trust mail headers
18
  	-${DIRBUILDER}
19
+ switch ("$1$2$3$4")
19
  
20
+ case "*[\t ]*":
20
  shownonascii: Xshownonascii
21
+   echo "Illegal white space in arguments\!"
21
! 	sed -e s@/u/nsb/lib/fonts@${PREFIX}/lib/metamail/fonts@ < Xshownonascii > shownonascii
22
+   echo "Command was:"
22
  	chmod +x shownonascii
23
+   echo "'$0' '$1' '$2' '$3' '$4'"
23
  
24
+   exit 2
24
  mailto-hebrew: Xmailto-hebrew
25
+ endsw
25
! 	sed -e s@/u/nsb/lib/fonts@${PREFIX}/lib/metamail/fonts@ < Xmailto-hebrew > mailto-hebrew
26
  	chmod +x mailto-hebrew
27
+ 
26
+ 
28
+ install:
27
+ # Set a sensible value for the temporary directory, if its not
29
+ 	mkdir -p ${PREFIX}/lib/metamail/fonts
28
+ # already set.  If TMPDIR is set previously, then we will
30
+ 	install -c heb6x13.${FONTSUFFIX} heb8x13.${FONTSUFFIX} \
29
+ # assume it is adequately protected.
31
+ 		heb8x13B.${FONTSUFFIX} fonts.alias ${PREFIX}/lib/metamail/fonts
30
  if (! $?METAMAIL_TMPDIR) then
32
+ 	if [ -d /usr/X11R6 ]; then mkfontdir ${PREFIX}/lib/metamail/fonts ; fi
31
!     if ($?TMPDIR) then
32
!         set METAMAIL_TMPDIR="$TMPDIR"
33
!     else
34
!         set METAMAIL_TMPDIR=~/metamail_tmp
35
!     endif
36
! endif
37
! 
38
! # Set a sensible umask value
39
! umask 077
40
! 
41
! # Make sure that the temporary directory is available
42
! if (! -d "$METAMAIL_TMPDIR") then
43
! 
44
!     if (! -e "$METAMAIL_TMPDIR") then
45
!         mkdir "$METAMAIL_TMPDIR"
46
!     else
47
!         echo "$METAMAIL_TMPDIR exists, but is not a directory"
48
!         exit 2
49
!     endif
50
! 
51
!     if ( $status != 0 || ! -d "$METAMAIL_TMPDIR" ) then
52
!         echo "Error creating $METAMAIL_TMPDIR"
53
!         exit 2
54
!     endif
55
! 
56
  endif
57
  
58
  set TREEROOT=${METAMAIL_TMPDIR}/m-prts-`whoami`
59
***************
60
*** 11,24 ****
61
      echo "Usage:  showpartial file id partnum totalnum"
62
      exit -1
63
  endif
64
! set file=$1
65
  # This next line is because message-id can contain weird chars
66
! set id=`echo $2 | tr -d  \!\$\&\*\(\)\|\'\"\;\/\<\>\\` 
67
! @ partnum = $3
68
! if ($#argv == 3 || $4 == "") then
69
      set totalnum=-1
70
  else
71
!     @ totalnum = $4
72
  endif
73
  
74
  if (! -d  $TREEROOT)  then
75
--- 47,60 ----
76
      echo "Usage:  showpartial file id partnum totalnum"
77
      exit -1
78
  endif
79
! set file="$1"
80
  # This next line is because message-id can contain weird chars
81
! set id=`echo "$2" | tr -d  \!\$\&\*\(\)\|\'\"\;\/\<\>\\` 
82
! @ partnum = "$3"
83
! if ($#argv == 3 || "$4" == "") then
84
      set totalnum=-1
85
  else
86
!     @ totalnum = "$4"
87
  endif
33
  
88
  
34
  clean:
89
  if (! -d  $TREEROOT)  then
35
  	rm -f heb6x13.${FONTSUFFIX} heb8x13.${FONTSUFFIX} heb8x13B.${FONTSUFFIX}  shownonascii mailto-hebrew fonts.dir
90
***************
91
*** 35,43 ****
92
          exit -1
93
      endif
94
  endif
95
! cp $file ${TREEROOT}/$id/$partnum
96
  if ($status) then 
97
!     echo cp $file ${TREEROOT}/$id/$partnum failed
98
      exit -1
99
  endif
100
  if ($totalnum == -1) then
101
--- 71,79 ----
102
          exit -1
103
      endif
104
  endif
105
! cp "$file" ${TREEROOT}/$id/$partnum
106
  if ($status) then 
107
!     echo cp "$file" ${TREEROOT}/$id/$partnum failed
108
      exit -1
109
  endif
110
  if ($totalnum == -1) then
(-)../metamail.new/files/patch-ae (-72 / +74 lines)
Lines 1-78 Link Here
1
*** metamail/splitmail.c.orig	Mon Jan 31 23:23:14 1994
1
diff -rc ./bin/showpicture /usr/ports/mail/metamail/work/mm2.7/src/bin/showpicture
2
--- metamail/splitmail.c	Sat Feb 28 19:17:32 2004
2
*** ./bin/showpicture	Mon Feb  7 18:59:54 1994
3
--- /usr/ports/mail/metamail/work/mm2.7/src/bin/showpicture	Sat Dec 16 22:21:45 2006
3
***************
4
***************
4
*** 41,48 ****
5
*** 15,29 ****
5
  #define VERBOSEDELIVERYCMD VerboseDeliveryCmd
6
  # WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES.
6
  #else
7
  #
7
  extern char *getenv();
8
! #define NORMALDELIVERYCMD "/usr/lib/sendmail -t -oi"
9
! #define VERBOSEDELIVERYCMD "/usr/lib/sendmail -t -v -oi"
10
  #endif
11
  
8
  
12
  usageexit() {
9
  if (! $?METAMAIL_TMPDIR) then
13
--- 41,48 ----
10
!     set METAMAIL_TMPDIR=/tmp
14
  #define VERBOSEDELIVERYCMD VerboseDeliveryCmd
11
  endif
15
  #else
16
  extern char *getenv();
17
! #define NORMALDELIVERYCMD "/usr/sbin/sendmail -t -oi"
18
! #define VERBOSEDELIVERYCMD "/usr/sbin/sendmail -t -v -oi"
19
  #endif
20
  
12
  
21
  usageexit() {
13
  if (! $?X_VIEWER) then
22
***************
14
! set X_VIEWER="xloadimage -view -quiet -geometry +1+1"
23
*** 194,200 ****
15
  # set X_VIEWER="xv -geometry +1+1"
24
  	s = endofheader(from);  /* would be index(from, '\n'),
16
  endif
25
  				 but need to check for continuation lines */
17
! if ($1 == "-viewer" && $#argv > 1) then
26
          *s = '\0';
18
      set X_VIEWER = "$2"
27
! 	if (ShareThisHeader(from, SubjectBuf, &OrigID)) {
19
      shift
28
  	    strcat(SharedHeaders, from);
20
      shift
29
  	    strcat(SharedHeaders, "\n");
21
--- 15,56 ----
30
  	}
22
  # WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES.
31
--- 194,200 ----
23
  #
32
  	s = endofheader(from);  /* would be index(from, '\n'),
33
  				 but need to check for continuation lines */
34
          *s = '\0';
35
! 	if (ShareThisHeader(from, SubjectBuf, sizeof(SubjectBuf), &OrigID)) {
36
  	    strcat(SharedHeaders, from);
37
  	    strcat(SharedHeaders, "\n");
38
  	}
39
***************
40
*** 339,347 ****
41
      NULL
42
  };
43
  
24
  
44
! ShareThisHeader(s, SubjectBuf, OrigID)
25
+ # Set a sensible value for the temporary directory, if its not
45
  char *s;
26
+ # already set.  If TMPDIR is set previously, then we will
46
  char *SubjectBuf;
27
+ # assume it is adequately protected.
47
  char **OrigID;
28
  if (! $?METAMAIL_TMPDIR) then
48
  {
29
!     if ($?TMPDIR) then
49
      int i;
30
!         set METAMAIL_TMPDIR="$TMPDIR"
50
--- 339,348 ----
31
!     else
51
      NULL
32
!         set METAMAIL_TMPDIR=~/metamail_tmp
52
  };
33
!     endif
34
! endif
35
! 
36
! # Set a sensible umask value
37
! umask 077
38
! 
39
! # Make sure that the temporary directory is available
40
! if (! -d "$METAMAIL_TMPDIR") then
41
! 
42
!     if (! -e "$METAMAIL_TMPDIR") then
43
!         mkdir "$METAMAIL_TMPDIR"
44
!     else
45
!         echo "$METAMAIL_TMPDIR exists, but is not a directory"
46
!         exit 2
47
!     endif
48
! 
49
!     if ( $status != 0 || ! -d "$METAMAIL_TMPDIR" ) then
50
!         echo "Error creating $METAMAIL_TMPDIR"
51
!         exit 2
52
!     endif
53
! 
54
  endif
53
  
55
  
54
! ShareThisHeader(s, SubjectBuf, size, OrigID)
56
  if (! $?X_VIEWER) then
55
  char *s;
57
!   set X_VIEWER="xloadimage -view -quiet -geometry +1+1"
56
  char *SubjectBuf;
58
  # set X_VIEWER="xv -geometry +1+1"
57
+ size_t size;
59
  endif
58
  char **OrigID;
60
! if ("$1" == "-viewer" && $#argv > 1) then
59
  {
61
      set X_VIEWER = "$2"
60
      int i;
62
      shift
63
      shift
61
***************
64
***************
62
*** 361,367 ****
65
*** 57,63 ****
63
      }
66
              endif
64
      if (!ULstrcmp(s, "subject")) {
67
          end
65
          *colon = ':';
68
      endif
66
!         strcpy(SubjectBuf, ++colon);
69
!     cp $1 $fname
67
          return(0);
70
      if ($status == 0) echo Wrote file $fname
68
      }
71
      exit 0
69
      if (!ULstrcmp(s, "content-type")) {
72
  endif
70
--- 362,369 ----
73
--- 84,90 ----
71
      }
74
              endif
72
      if (!ULstrcmp(s, "subject")) {
75
          end
73
          *colon = ':';
76
      endif
74
!         strncpy(SubjectBuf, ++colon, size);
77
!     cp "$1" $fname
75
!         SubjectBuf[size - 1] = '\0';
78
      if ($status == 0) echo Wrote file $fname
76
          return(0);
79
      exit 0
77
      }
80
  endif
78
      if (!ULstrcmp(s, "content-type")) {
(-)../metamail.new/files/patch-af (-258 / +18 lines)
Lines 1-260 Link Here
1
*** metamail.old/mailto.c	Wed Feb  9 21:30:26 1994
1
diff -rc ./bin/sun2mime /usr/ports/mail/metamail/work/mm2.7/src/bin/sun2mime
2
--- metamail/mailto.c	Thu Jul 29 14:32:28 2004
2
*** ./bin/sun2mime	Sat Nov 13 15:54:05 1993
3
***************
3
--- /usr/ports/mail/metamail/work/mm2.7/src/bin/sun2mime	Sat Dec 16 22:21:45 2006
4
*** 570,575 ****
4
***************
5
--- 570,576 ----
5
*** 11,17 ****
6
          if (isupper(*sdum)) *sdum = tolower(*sdum);
6
  fi
7
      }
7
  TMPFILE=${METAMAIL_TMPDIR}/suntomime.$$
8
      if (strcmp(CharacterSet, "us-ascii")
9
+ 	 && strcmp(CharacterSet, "koi8-r")
10
           && strncmp(CharacterSet, "iso-8859-", 9)) {
11
          fprintf(stderr, "mailto:  Unsupported character set: %s\n", CharacterSet);
12
          exit(-1);
13
***************
14
*** 1130,1135 ****
15
--- 1131,1137 ----
16
          if (part->isrich) {
17
              if (strcmp(CharacterSet, "us-ascii")
18
                   && (strncmp(CharacterSet, "iso-8859-", 9) 
19
+ 		     && strcmp(CharacterSet, "koi8-r")
20
                        || part->encoding_type_needed != ENC_NONE)) {
21
                  fprintf(fp, "Content-type: text/richtext; charset=\"%s\"\n", CharacterSet);
22
              } else {
23
***************
24
*** 1140,1145 ****
25
--- 1142,1148 ----
26
              WriteCtypeNicely(fp, part->content_type);
27
              if (strcmp(CharacterSet, "us-ascii")
28
                   && (strncmp(CharacterSet, "iso-8859-", 9) 
29
+ 		     && strcmp(CharacterSet, "koi8-r")
30
                        || part->encoding_type_needed != ENC_NONE)) {
31
                  fprintf(fp, "; charset=\"%s\"\n", CharacterSet);
32
              } else fputs("\n", fp);
33
***************
34
*** 1745,1750 ****
35
--- 1748,1754 ----
36
      }
37
      printf("\n\nEnter your choice as a number from 0 to %d: ", i);
38
      fflush(stdout);
39
+     *LineBuf = '\0';
40
      fgets(LineBuf, sizeof(LineBuf), stdin);
41
      ans = atoi(LineBuf);
42
      if (ans == 0 || ans == 1) {
43
***************
44
*** 1752,1759 ****
45
          FILE *fpi, *fpo;
46
  	printf("\nIf you want to include non-textual data from a file, enter the file name.\nTo include the output of a command, enter \"|\" followed by the command.\nIf you do not want to include anything, just press ENTER (RETURN).\n> ");
47
          fflush(stdout);
48
          fgets(CTLineBuf, sizeof(CTLineBuf), stdin);
49
!         sdum = CTLineBuf+strlen(CTLineBuf) -1;
50
          while (sdum >= CTLineBuf && isspace((unsigned char) *sdum)) {
51
              *sdum = '\0';
52
              --sdum;
53
--- 1756,1764 ----
54
          FILE *fpi, *fpo;
55
  	printf("\nIf you want to include non-textual data from a file, enter the file name.\nTo include the output of a command, enter \"|\" followed by the command.\nIf you do not want to include anything, just press ENTER (RETURN).\n> ");
56
          fflush(stdout);
57
+         *CTLineBuf = '\0';
58
          fgets(CTLineBuf, sizeof(CTLineBuf), stdin);
59
!         sdum = *CTLineBuf ? CTLineBuf+strlen(CTLineBuf) -1 : CTLineBuf;
60
          while (sdum >= CTLineBuf && isspace((unsigned char) *sdum)) {
61
              *sdum = '\0';
62
              --sdum;
63
***************
64
*** 1791,1797 ****
65
                  int ct;
66
                  printf("\nEnter the MIME Content-type value for the data from file %s\n    (type '?' for a list of locally-valid content-types): ", sdum);
67
                  fflush(stdout);
68
!                 gets(LineBuf);
69
                  if (index(LineBuf, '/')) {
70
                      char lc[100], *s, AnsBuf[100];
71
                      strcpy(lc, LineBuf);
72
--- 1796,1805 ----
73
                  int ct;
74
                  printf("\nEnter the MIME Content-type value for the data from file %s\n    (type '?' for a list of locally-valid content-types): ", sdum);
75
                  fflush(stdout);
76
!                 *LineBuf = '\0';
77
!                 fgets(LineBuf, sizeof(LineBuf), stdin);
78
!                 if (*LineBuf)
79
!                     LineBuf[strlen(LineBuf) - 1] = '\0';
80
                  if (index(LineBuf, '/')) {
81
                      char lc[100], *s, AnsBuf[100];
82
                      strcpy(lc, LineBuf);
83
***************
84
*** 1809,1815 ****
85
                      }
86
                      if (mc) break;
87
                      printf("The MIME content-type '%s' is not listed in your local mailcap files,\nand may not be a valid MIME type.  Do you want to use it anyway [no] ? ", LineBuf);
88
!                     s = gets(AnsBuf);
89
                      while (s && *s && isspace((unsigned char) *s)) ++s;
90
                      if (s && (*s == 'y' || *s == 'Y')) break;
91
                      continue;
92
--- 1817,1823 ----
93
                      }
94
                      if (mc) break;
95
                      printf("The MIME content-type '%s' is not listed in your local mailcap files,\nand may not be a valid MIME type.  Do you want to use it anyway [no] ? ", LineBuf);
96
!                     s = fgets(AnsBuf, sizeof(AnsBuf), stdin);
97
                      while (s && *s && isspace((unsigned char) *s)) ++s;
98
                      if (s && (*s == 'y' || *s == 'Y')) break;
99
                      continue;
100
***************
101
*** 2137,2142 ****
102
--- 2145,2151 ----
103
              printf("2: %s\n", CmdBuf);
104
              printf("\n\nEnter 1 or 2, or 0 to not edit it: ");
105
              fflush(stdout);
106
+             *LineBuf = '\0';
107
              fgets(LineBuf, sizeof(LineBuf), stdin);
108
              ans = atoi(LineBuf);
109
          } else ans = 2;
110
*** metamail.old/metamail.c	Thu Feb 17 02:57:19 1994
111
--- metamail/metamail.c	Wed Mar  9 21:30:22 2005
112
***************
113
*** 83,89 ****
114
  #define MAX_FILE_NAME_SIZE 256
115
  #define WRITE_BINARY	"w"
116
  #else /* AMIGA */
117
! extern char **environ, *gets();
118
  #define CATCOMMAND  "cat"
119
  #define CATTEMPLATE "cat %s"
120
  #define METAMAIL    "metamail"
121
--- 83,89 ----
122
  #define MAX_FILE_NAME_SIZE 256
123
  #define WRITE_BINARY	"w"
124
  #else /* AMIGA */
125
! extern char **environ;
126
  #define CATCOMMAND  "cat"
127
  #define CATTEMPLATE "cat %s"
128
  #define METAMAIL    "metamail"
129
***************
130
*** 540,545 ****
131
--- 540,546 ----
132
                      ans = 2;
133
                  } else {
134
                      printf("\nWhat do you want to do with the %s data?\n1 -- See it as text\n2 -- Write it to a file\n3 -- Just skip it\n\n", octetstream ? "raw" : ContentType);
135
+                     *Fname = '\0';
136
                      fgets(Fname, sizeof(Fname), stdin);
137
                      ans = atoi(Fname);
138
                  }
139
***************
140
*** 554,561 ****
141
                              needname = 0;
142
                              printf("Please enter the name of a file to which the data should be written\n(Default: %s) > ", suggestedname);
143
                              fflush(stdout);
144
                              fgets(Fname, sizeof(Fname), stdin);
145
!                             Fname[strlen(Fname) - 1] = '\0'; /* bogus newline */
146
  #if !defined(AMIGA) && !defined(MSDOS)
147
                              if (!Fname[0]) strcpy(Fname, suggestedname);
148
                              if (Fname[0] == '~' && Fname[1] == '/') {
149
--- 555,564 ----
150
                              needname = 0;
151
                              printf("Please enter the name of a file to which the data should be written\n(Default: %s) > ", suggestedname);
152
                              fflush(stdout);
153
+                             *Fname = '\0';
154
                              fgets(Fname, sizeof(Fname), stdin);
155
!                             if (*Fname)
156
!                                 Fname[strlen(Fname) - 1] = '\0'; /* bogus newline */
157
  #if !defined(AMIGA) && !defined(MSDOS)
158
                              if (!Fname[0]) strcpy(Fname, suggestedname);
159
                              if (Fname[0] == '~' && Fname[1] == '/') {
160
***************
161
*** 579,588 ****
162
                                  int overwriteans = -1;
163
                                  do {
164
                                      printf("File %s exists.  Do you want to overwrite it (y/n) ?\n", Fname);
165
!                                     s = gets(AnsBuf);
166
                                      if (!s) {
167
                                          overwriteans = 0;
168
                                      } else {
169
                                          while (s && *s && isspace((unsigned char) *s)) ++s;
170
                                          if (*s == 'y' || *s == 'Y' || !*s || *s == '\n') {
171
                                              overwriteans = 1;
172
--- 582,593 ----
173
                                  int overwriteans = -1;
174
                                  do {
175
                                      printf("File %s exists.  Do you want to overwrite it (y/n) ?\n", Fname);
176
!                                     *AnsBuf = '\0';
177
!                                     s = fgets(AnsBuf, sizeof(AnsBuf), stdin);
178
                                      if (!s) {
179
                                          overwriteans = 0;
180
                                      } else {
181
+                                         s[strlen(s) - 1] = '\0';
182
                                          while (s && *s && isspace((unsigned char) *s)) ++s;
183
                                          if (*s == 'y' || *s == 'Y' || !*s || *s == '\n') {
184
                                              overwriteans = 1;
185
***************
186
*** 1202,1210 ****
187
      fprintf(outfp, "Content-type: %s", ContentType);
188
      for (j=0; j<CParamsUsed; ++j) {
189
          fprintf(outfp, " ; ");
190
!         fprintf(outfp, CParams[j]);
191
          fprintf(outfp, " = ");
192
!         fprintf(outfp, CParamValues[j]);
193
      }
194
      fprintf(outfp, "\n\n"); 
195
      TranslateInputToOutput(InputFP, outfp, EncodingCode, ContentType);
196
--- 1207,1215 ----
197
      fprintf(outfp, "Content-type: %s", ContentType);
198
      for (j=0; j<CParamsUsed; ++j) {
199
          fprintf(outfp, " ; ");
200
!         fprintf(outfp, "%s", CParams[j]);
201
          fprintf(outfp, " = ");
202
!         fprintf(outfp, "%s", CParamValues[j]);
203
      }
204
      fprintf(outfp, "\n\n"); 
205
      TranslateInputToOutput(InputFP, outfp, EncodingCode, ContentType);
206
***************
207
*** 1823,1830 ****
208
          } else {
209
              printf("This message contains '%s'-format data.\nDo you want to view it using the '%s' command (y/n) [y] ? ", ctype, ShortCommand(progname));
210
          }
211
!         s = gets(AnsBuf);
212
          if (!s) return(0); /* EOF */
213
  	while (s && *s && isspace((unsigned char) *s)) ++s;
214
  	if (*s == 'y' || *s == 'Y' || !*s || *s == '\n') return(1);
215
  	if (*s == 'n' || *s == 'N' || *s == 'q' || *s == 'Q') {
216
--- 1828,1836 ----
217
          } else {
218
              printf("This message contains '%s'-format data.\nDo you want to view it using the '%s' command (y/n) [y] ? ", ctype, ShortCommand(progname));
219
          }
220
!         s = fgets(AnsBuf, sizeof(AnsBuf), stdin);
221
          if (!s) return(0); /* EOF */
222
+         s[strlen(s) - 1] = '\0';
223
  	while (s && *s && isspace((unsigned char) *s)) ++s;
224
  	if (*s == 'y' || *s == 'Y' || !*s || *s == '\n') return(1);
225
  	if (*s == 'n' || *s == 'N' || *s == 'q' || *s == 'Q') {
226
***************
227
*** 2022,2028 ****
228
      if (lc2strcmp(charset, PrevCharset)) {
229
          char *s2, *charsetinuse;
230
  
8
  
231
!         strcpy(PrevCharset, charset);
9
! /bin/nawk '
232
          for (s2=PrevCharset; *s2; ++s2) {
10
    BEGIN { printf("Content-type: multipart/mixed; boundary=--------\n\n")
233
              if (isupper((unsigned char) *s2)) *s2 = tolower((unsigned char) *s2);
11
            RS=""; FS="\n"; mode="HEADER" }
234
          }
12
    mode == "HEADER" {
235
--- 2028,2035 ----
13
--- 11,17 ----
236
      if (lc2strcmp(charset, PrevCharset)) {
14
  fi
237
          char *s2, *charsetinuse;
15
  TMPFILE=${METAMAIL_TMPDIR}/suntomime.$$
238
  
16
  
239
!         strncpy(PrevCharset, charset, sizeof(PrevCharset));
17
! /usr/bin/awk '
240
!         PrevCharset[sizeof(PrevCharset) - 1] = '\0';
18
    BEGIN { printf("Content-type: multipart/mixed; boundary=--------\n\n")
241
          for (s2=PrevCharset; *s2; ++s2) {
19
            RS=""; FS="\n"; mode="HEADER" }
242
              if (isupper((unsigned char) *s2)) *s2 = tolower((unsigned char) *s2);
20
    mode == "HEADER" {
243
          }
244
***************
245
*** 2032,2038 ****
246
          }
247
      }
248
      if (ecode == ENCODING_NONE) {
249
!         printf(txt+1);
250
      } else {
251
          /* What follows is REALLY bogus, but all my encoding stuff is pipe-oriented right now... */
252
          MkTmpFileName(TmpFile);
253
--- 2039,2045 ----
254
          }
255
      }
256
      if (ecode == ENCODING_NONE) {
257
!         printf("%s", txt+1);
258
      } else {
259
          /* What follows is REALLY bogus, but all my encoding stuff is pipe-oriented right now... */
260
          MkTmpFileName(TmpFile);
(-)../metamail.new/files/patch-ag (-260 / +35 lines)
Lines 1-260 Link Here
1
diff -u -r mm2.7.org/src/bin/showaudio mm2.7/src/bin/showaudio
1
diff -rc ./config.h /usr/ports/mail/metamail/work/mm2.7/src/config.h
2
--- bin/showaudio	Wed Feb  2 16:21:26 1994
2
*** ./config.h	Wed Nov 24 16:36:07 1993
3
+++ bin/showaudio	Wed May 21 21:34:08 1997
3
--- /usr/ports/mail/metamail/work/mm2.7/src/config.h	Sat Dec 16 22:21:45 2006
4
@@ -15,9 +15,35 @@
4
***************
5
 # WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES.
5
*** 73,79 ****
6
 #
6
  #ifdef SYSV
7
 
7
  #define RESET_PROGRAM "tput clear"
8
-
8
  #else
9
+# Set a sensible value for the temporary directory, if its not
9
! #ifdef __BSD_4_4__
10
+# already set.  If TMPDIR is set previously, then we will
10
  #define RESET_PROGRAM "/usr/bin/reset"
11
+# assume it is adequately protected.
11
  #else
12
 if (! $?METAMAIL_TMPDIR) then
12
  #define RESET_PROGRAM "/usr/ucb/reset"
13
-    set METAMAIL_TMPDIR=/tmp
13
--- 73,79 ----
14
+    if ($?TMPDIR) then
14
  #ifdef SYSV
15
+        set METAMAIL_TMPDIR="$TMPDIR"
15
  #define RESET_PROGRAM "tput clear"
16
+    else
16
  #else
17
+        set METAMAIL_TMPDIR=~/metamail_tmp
17
! #if defined(__BSD_4_4__) || defined(__FreeBSD__)
18
+    endif
18
  #define RESET_PROGRAM "/usr/bin/reset"
19
+endif
19
  #else
20
+
20
  #define RESET_PROGRAM "/usr/ucb/reset"
21
+# Set a sensible umask value
21
***************
22
+umask 077
22
*** 155,161 ****
23
+
23
--- 155,165 ----
24
+# Make sure that the temporary directory is available
24
  #ifdef NeXT
25
+if (! -d "$METAMAIL_TMPDIR") then
25
  #define sigtype void
26
+
26
  #else
27
+    if (! -e "$METAMAIL_TMPDIR") then
27
+ #ifdef __FreeBSD__
28
+        mkdir "$METAMAIL_TMPDIR"
28
+ #define sigtype void
29
+    else
29
+ #else
30
+        echo "$METAMAIL_TMPDIR exists, but is not a directory"
30
  #define sigtype int
31
+        exit 2
31
+ #endif
32
+    endif
32
  #endif
33
+
33
  #endif
34
+    if ( $status != 0 || ! -d "$METAMAIL_TMPDIR" ) then
34
  
35
+        echo "Error creating $METAMAIL_TMPDIR"
35
Only in /usr/ports/mail/metamail/work/mm2.7/src/: config.h.orig
36
+        exit 2
37
+    endif
38
+
39
 endif
40
 
41
 # First, figure out which machine to play it on!
42
@@ -33,7 +59,7 @@
43
 set ORG="Bellcore"
44
 set STDINPUT=0
45
 if ("$1" == "-p") then
46
-    set AUDIOPHONE=$2
47
+    set AUDIOPHONE="$2"
48
     shift
49
     shift
50
 endif
51
@@ -173,7 +199,7 @@
52
 	    set AUDIOPHONE=$<
53
 	endif
54
 	if ($thishost == $AUDIOPHONEHOST || $thishost == $AUDIOPHONEHOSTLONG) then
55
-	    echo Calling Phone number $AUDIOPHONE
56
+	    echo Calling Phone number "$AUDIOPHONE"
57
 	    echo "You MUST SAY HELLO when you answer the phone, or you will not hear the message."
58
 	    mail -s "showaudio: `whoami` called $AUDIOPHONE" $AUDIOLOGMAIL < /dev/null
59
 	    if ($STDINPUT) then
60
@@ -206,7 +232,7 @@
61
     echo -n "File name:"
62
     set fname=$<
63
 endif
64
-cp $1 $fname
65
+cp "$1" $fname
66
 if ($status == 0) echo Wrote raw audio file: $fname
67
 exit 0
68
 
69
Only in mm2.7/src/bin: showaudio~
70
diff -u -r mm2.7.org/src/bin/showexternal mm2.7/src/bin/showexternal
71
--- bin/showexternal	Tue Feb  8 09:39:05 1994
72
+++ bin/showexternal	Wed May 21 21:41:39 1997
73
@@ -15,9 +15,45 @@
74
 # WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES.
75
 # 
76
 
77
+# Check argument integrity. Don't trust mail headers
78
+switch ("$1$2$3$4$5$6$7")
79
+case "*[\t ]*":
80
+  echo "Illegal white space in arguments\!"
81
+  echo "Command was:"
82
+  echo "'$0' '$1' '$2' '$3' '$4' '$5' '$6' '$7'"
83
+  exit 2
84
+endsw
85
+
86
 onintr cleanup
87
+# Set a sensible value for the temporary directory, if its not
88
+# already set.  If TMPDIR is set previously, then we will
89
+# assume it is adequately protected.
90
 if (! $?METAMAIL_TMPDIR) then
91
-    set METAMAIL_TMPDIR=/tmp
92
+    if ($?TMPDIR) then
93
+        set METAMAIL_TMPDIR="$TMPDIR"
94
+    else
95
+        set METAMAIL_TMPDIR=~/metamail_tmp
96
+    endif
97
+endif
98
+
99
+# Set a sensible umask value
100
+umask 077
101
+
102
+# Make sure that the temporary directory is available
103
+if (! -d "$METAMAIL_TMPDIR") then
104
+
105
+    if (! -e "$METAMAIL_TMPDIR") then
106
+        mkdir "$METAMAIL_TMPDIR"
107
+    else
108
+        echo "$METAMAIL_TMPDIR exists, but is not a directory"
109
+        exit 2
110
+    endif
111
+
112
+    if ( $status != 0 || ! -d "$METAMAIL_TMPDIR" ) then
113
+        echo "Error creating $METAMAIL_TMPDIR"
114
+        exit 2
115
+    endif
116
+
117
 endif
118
 if (! $?FTP) then
119
     set FTP=ftp
120
Only in mm2.7/src/bin: showexternal~
121
diff -u -r mm2.7.org/src/bin/showpartial mm2.7/src/bin/showpartial
122
--- bin/showpartial	Wed Feb  2 16:21:29 1994
123
+++ bin/showpartial	Wed May 21 21:39:49 1997
124
@@ -2,8 +2,44 @@
125
 # (The "-fb" might need to be changed to "-f" on some systems)
126
 #
127
 
128
+# Check argument integrity. Don't trust mail headers
129
+switch ("$1$2$3$4")
130
+case "*[\t ]*":
131
+  echo "Illegal white space in arguments\!"
132
+  echo "Command was:"
133
+  echo "'$0' '$1' '$2' '$3' '$4'"
134
+  exit 2
135
+endsw
136
+
137
+# Set a sensible value for the temporary directory, if its not
138
+# already set.  If TMPDIR is set previously, then we will
139
+# assume it is adequately protected.
140
 if (! $?METAMAIL_TMPDIR) then
141
-    set METAMAIL_TMPDIR=/tmp
142
+    if ($?TMPDIR) then
143
+        set METAMAIL_TMPDIR="$TMPDIR"
144
+    else
145
+        set METAMAIL_TMPDIR=~/metamail_tmp
146
+    endif
147
+endif
148
+
149
+# Set a sensible umask value
150
+umask 077
151
+
152
+# Make sure that the temporary directory is available
153
+if (! -d "$METAMAIL_TMPDIR") then
154
+
155
+    if (! -e "$METAMAIL_TMPDIR") then
156
+        mkdir "$METAMAIL_TMPDIR"
157
+    else
158
+        echo "$METAMAIL_TMPDIR exists, but is not a directory"
159
+        exit 2
160
+    endif
161
+
162
+    if ( $status != 0 || ! -d "$METAMAIL_TMPDIR" ) then
163
+        echo "Error creating $METAMAIL_TMPDIR"
164
+        exit 2
165
+    endif
166
+
167
 endif
168
 
169
 set TREEROOT=${METAMAIL_TMPDIR}/m-prts-`whoami`
170
@@ -11,14 +47,14 @@
171
     echo "Usage:  showpartial file id partnum totalnum"
172
     exit -1
173
 endif
174
-set file=$1
175
+set file="$1"
176
 # This next line is because message-id can contain weird chars
177
-set id=`echo $2 | tr -d  \!\$\&\*\(\)\|\'\"\;\/\<\>\\` 
178
-@ partnum = $3
179
-if ($#argv == 3 || $4 == "") then
180
+set id=`echo "$2" | tr -d  \!\$\&\*\(\)\|\'\"\;\/\<\>\\` 
181
+@ partnum = "$3"
182
+if ($#argv == 3 || "$4" == "") then
183
     set totalnum=-1
184
 else
185
-    @ totalnum = $4
186
+    @ totalnum = "$4"
187
 endif
188
 
189
 if (! -d  $TREEROOT)  then
190
@@ -35,9 +71,9 @@
191
         exit -1
192
     endif
193
 endif
194
-cp $file ${TREEROOT}/$id/$partnum
195
+cp "$file" ${TREEROOT}/$id/$partnum
196
 if ($status) then 
197
-    echo cp $file ${TREEROOT}/$id/$partnum failed
198
+    echo cp "$file" ${TREEROOT}/$id/$partnum failed
199
     exit -1
200
 endif
201
 if ($totalnum == -1) then
202
Only in mm2.7/src/bin: showpartial~
203
diff -u -r mm2.7.org/src/bin/showpicture mm2.7/src/bin/showpicture
204
--- bin/showpicture	Mon Feb  7 10:59:54 1994
205
+++ bin/showpicture	Wed May 21 21:34:59 1997
206
@@ -15,15 +15,42 @@
207
 # WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES.
208
 #
209
 
210
+# Set a sensible value for the temporary directory, if its not
211
+# already set.  If TMPDIR is set previously, then we will
212
+# assume it is adequately protected.
213
 if (! $?METAMAIL_TMPDIR) then
214
-    set METAMAIL_TMPDIR=/tmp
215
+    if ($?TMPDIR) then
216
+        set METAMAIL_TMPDIR="$TMPDIR"
217
+    else
218
+        set METAMAIL_TMPDIR=~/metamail_tmp
219
+    endif
220
+endif
221
+
222
+# Set a sensible umask value
223
+umask 077
224
+
225
+# Make sure that the temporary directory is available
226
+if (! -d "$METAMAIL_TMPDIR") then
227
+
228
+    if (! -e "$METAMAIL_TMPDIR") then
229
+        mkdir "$METAMAIL_TMPDIR"
230
+    else
231
+        echo "$METAMAIL_TMPDIR exists, but is not a directory"
232
+        exit 2
233
+    endif
234
+
235
+    if ( $status != 0 || ! -d "$METAMAIL_TMPDIR" ) then
236
+        echo "Error creating $METAMAIL_TMPDIR"
237
+        exit 2
238
+    endif
239
+
240
 endif
241
 
242
 if (! $?X_VIEWER) then
243
-set X_VIEWER="xloadimage -view -quiet -geometry +1+1"
244
+  set X_VIEWER="xloadimage -view -quiet -geometry +1+1"
245
 # set X_VIEWER="xv -geometry +1+1"
246
 endif
247
-if ($1 == "-viewer" && $#argv > 1) then
248
+if ("$1" == "-viewer" && $#argv > 1) then
249
     set X_VIEWER = "$2"
250
     shift
251
     shift
252
@@ -57,7 +84,7 @@
253
             endif
254
         end
255
     endif
256
-    cp $1 $fname
257
+    cp "$1" $fname
258
     if ($status == 0) echo Wrote file $fname
259
     exit 0
260
 endif
(-)../metamail.new/files/patch-ah (+37 lines)
Line 0 Link Here
1
diff -rc ./fonts/Makefile /usr/ports/mail/metamail/work/mm2.7/src/fonts/Makefile
2
*** ./fonts/Makefile	Mon May 31 22:49:27 1993
3
--- /usr/ports/mail/metamail/work/mm2.7/src/fonts/Makefile	Sat Dec 16 22:21:45 2006
4
***************
5
*** 28,39 ****
6
  	-${DIRBUILDER}
7
  
8
  shownonascii: Xshownonascii
9
! 	sed -e s@/u/nsb/lib/fonts@`pwd`@ < Xshownonascii > shownonascii
10
  	chmod +x shownonascii
11
  
12
  mailto-hebrew: Xmailto-hebrew
13
! 	sed -e s@/u/nsb/lib/fonts@`pwd`@ < Xmailto-hebrew > mailto-hebrew
14
  	chmod +x mailto-hebrew
15
  
16
  clean:
17
  	rm -f heb6x13.${FONTSUFFIX} heb8x13.${FONTSUFFIX} heb8x13B.${FONTSUFFIX}  shownonascii mailto-hebrew fonts.dir
18
--- 28,45 ----
19
  	-${DIRBUILDER}
20
  
21
  shownonascii: Xshownonascii
22
! 	sed -e s@/u/nsb/lib/fonts@${PREFIX}/lib/metamail/fonts@ < Xshownonascii > shownonascii
23
  	chmod +x shownonascii
24
  
25
  mailto-hebrew: Xmailto-hebrew
26
! 	sed -e s@/u/nsb/lib/fonts@${PREFIX}/lib/metamail/fonts@ < Xmailto-hebrew > mailto-hebrew
27
  	chmod +x mailto-hebrew
28
+ 
29
+ install:
30
+ 	mkdir -p ${PREFIX}/lib/metamail/fonts
31
+ 	install -c heb6x13.${FONTSUFFIX} heb8x13.${FONTSUFFIX} \
32
+ 		heb8x13B.${FONTSUFFIX} fonts.alias ${PREFIX}/lib/metamail/fonts
33
+ 	if [ -d /usr/X11R6 ]; then mkfontdir ${PREFIX}/lib/metamail/fonts ; fi
34
  
35
  clean:
36
  	rm -f heb6x13.${FONTSUFFIX} heb8x13.${FONTSUFFIX} heb8x13B.${FONTSUFFIX}  shownonascii mailto-hebrew fonts.dir
37
Only in /usr/ports/mail/metamail/work/mm2.7/src/fonts: Makefile.orig
(-)../metamail.new/files/patch-ai (+16 lines)
Line 0 Link Here
1
diff -rc ./metamail/codes.c /usr/ports/mail/metamail/work/mm2.7/src/metamail/codes.c
2
*** ./metamail/codes.c	Mon Sep 20 15:13:22 1993
3
--- /usr/ports/mail/metamail/work/mm2.7/src/metamail/codes.c	Sat Dec 16 22:21:45 2006
4
***************
5
*** 13,18 ****
6
--- 13,19 ----
7
  WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES.
8
  */
9
  #include <stdio.h>
10
+ #include <string.h>
11
  #include <ctype.h>
12
  #include <config.h>
13
  
14
Only in /usr/ports/mail/metamail/work/mm2.7/src/metamail: codes.c.orig
15
Only in /usr/ports/mail/metamail/work/mm2.7/src/metamail: codes.o
16
Only in /usr/ports/mail/metamail/work/mm2.7/src/metamail: mailto
(-)../metamail.new/files/patch-aj (+134 lines)
Line 0 Link Here
1
diff -rc ./metamail/mailto.c /usr/ports/mail/metamail/work/mm2.7/src/metamail/mailto.c
2
*** ./metamail/mailto.c	Wed Feb  9 21:30:26 1994
3
--- /usr/ports/mail/metamail/work/mm2.7/src/metamail/mailto.c	Sat Dec 16 22:21:45 2006
4
***************
5
*** 37,42 ****
6
--- 37,44 ----
7
  */
8
  
9
  #include <stdio.h>
10
+ #include <stdlib.h>
11
+ #include <string.h>
12
  #include <ctype.h>
13
  #include <config.h>
14
  #include <pwd.h>
15
***************
16
*** 60,66 ****
17
  #include <unistd.h>
18
  #endif
19
  
20
- extern char *malloc(), *realloc(), *index(), *getmyname();
21
  struct mailpart *CreateNewPart();
22
  
23
  /* The main data structure for the multiple parts of the mail */
24
--- 62,67 ----
25
***************
26
*** 570,575 ****
27
--- 571,577 ----
28
          if (isupper(*sdum)) *sdum = tolower(*sdum);
29
      }
30
      if (strcmp(CharacterSet, "us-ascii")
31
+ 	 && strcmp(CharacterSet, "koi8-r")
32
           && strncmp(CharacterSet, "iso-8859-", 9)) {
33
          fprintf(stderr, "mailto:  Unsupported character set: %s\n", CharacterSet);
34
          exit(-1);
35
***************
36
*** 1130,1135 ****
37
--- 1132,1138 ----
38
          if (part->isrich) {
39
              if (strcmp(CharacterSet, "us-ascii")
40
                   && (strncmp(CharacterSet, "iso-8859-", 9) 
41
+ 		     && strcmp(CharacterSet, "koi8-r")
42
                        || part->encoding_type_needed != ENC_NONE)) {
43
                  fprintf(fp, "Content-type: text/richtext; charset=\"%s\"\n", CharacterSet);
44
              } else {
45
***************
46
*** 1140,1145 ****
47
--- 1143,1149 ----
48
              WriteCtypeNicely(fp, part->content_type);
49
              if (strcmp(CharacterSet, "us-ascii")
50
                   && (strncmp(CharacterSet, "iso-8859-", 9) 
51
+ 		     && strcmp(CharacterSet, "koi8-r")
52
                        || part->encoding_type_needed != ENC_NONE)) {
53
                  fprintf(fp, "; charset=\"%s\"\n", CharacterSet);
54
              } else fputs("\n", fp);
55
***************
56
*** 1745,1750 ****
57
--- 1749,1755 ----
58
      }
59
      printf("\n\nEnter your choice as a number from 0 to %d: ", i);
60
      fflush(stdout);
61
+     *LineBuf = '\0';
62
      fgets(LineBuf, sizeof(LineBuf), stdin);
63
      ans = atoi(LineBuf);
64
      if (ans == 0 || ans == 1) {
65
***************
66
*** 1752,1759 ****
67
          FILE *fpi, *fpo;
68
  	printf("\nIf you want to include non-textual data from a file, enter the file name.\nTo include the output of a command, enter \"|\" followed by the command.\nIf you do not want to include anything, just press ENTER (RETURN).\n> ");
69
          fflush(stdout);
70
          fgets(CTLineBuf, sizeof(CTLineBuf), stdin);
71
!         sdum = CTLineBuf+strlen(CTLineBuf) -1;
72
          while (sdum >= CTLineBuf && isspace((unsigned char) *sdum)) {
73
              *sdum = '\0';
74
              --sdum;
75
--- 1757,1765 ----
76
          FILE *fpi, *fpo;
77
  	printf("\nIf you want to include non-textual data from a file, enter the file name.\nTo include the output of a command, enter \"|\" followed by the command.\nIf you do not want to include anything, just press ENTER (RETURN).\n> ");
78
          fflush(stdout);
79
+         *CTLineBuf = '\0';
80
          fgets(CTLineBuf, sizeof(CTLineBuf), stdin);
81
!         sdum = *CTLineBuf ? CTLineBuf+strlen(CTLineBuf) -1 : CTLineBuf;
82
          while (sdum >= CTLineBuf && isspace((unsigned char) *sdum)) {
83
              *sdum = '\0';
84
              --sdum;
85
***************
86
*** 1791,1797 ****
87
                  int ct;
88
                  printf("\nEnter the MIME Content-type value for the data from file %s\n    (type '?' for a list of locally-valid content-types): ", sdum);
89
                  fflush(stdout);
90
!                 gets(LineBuf);
91
                  if (index(LineBuf, '/')) {
92
                      char lc[100], *s, AnsBuf[100];
93
                      strcpy(lc, LineBuf);
94
--- 1797,1806 ----
95
                  int ct;
96
                  printf("\nEnter the MIME Content-type value for the data from file %s\n    (type '?' for a list of locally-valid content-types): ", sdum);
97
                  fflush(stdout);
98
!                 *LineBuf = '\0';
99
!                 fgets(LineBuf, sizeof(LineBuf), stdin);
100
!                 if (*LineBuf)
101
!                     LineBuf[strlen(LineBuf) - 1] = '\0';
102
                  if (index(LineBuf, '/')) {
103
                      char lc[100], *s, AnsBuf[100];
104
                      strcpy(lc, LineBuf);
105
***************
106
*** 1809,1815 ****
107
                      }
108
                      if (mc) break;
109
                      printf("The MIME content-type '%s' is not listed in your local mailcap files,\nand may not be a valid MIME type.  Do you want to use it anyway [no] ? ", LineBuf);
110
!                     s = gets(AnsBuf);
111
                      while (s && *s && isspace((unsigned char) *s)) ++s;
112
                      if (s && (*s == 'y' || *s == 'Y')) break;
113
                      continue;
114
--- 1818,1824 ----
115
                      }
116
                      if (mc) break;
117
                      printf("The MIME content-type '%s' is not listed in your local mailcap files,\nand may not be a valid MIME type.  Do you want to use it anyway [no] ? ", LineBuf);
118
!                     s = fgets(AnsBuf, sizeof(AnsBuf), stdin);
119
                      while (s && *s && isspace((unsigned char) *s)) ++s;
120
                      if (s && (*s == 'y' || *s == 'Y')) break;
121
                      continue;
122
***************
123
*** 2137,2142 ****
124
--- 2146,2152 ----
125
              printf("2: %s\n", CmdBuf);
126
              printf("\n\nEnter 1 or 2, or 0 to not edit it: ");
127
              fflush(stdout);
128
+             *LineBuf = '\0';
129
              fgets(LineBuf, sizeof(LineBuf), stdin);
130
              ans = atoi(LineBuf);
131
          } else ans = 2;
132
Only in /usr/ports/mail/metamail/work/mm2.7/src/metamail: mailto.c.orig
133
Only in /usr/ports/mail/metamail/work/mm2.7/src/metamail: mailto.o
134
Only in /usr/ports/mail/metamail/work/mm2.7/src/metamail: metamail
(-)../metamail.new/files/patch-ak (+201 lines)
Line 0 Link Here
1
diff -rc ./metamail/metamail.c /usr/ports/mail/metamail/work/mm2.7/src/metamail/metamail.c
2
*** ./metamail/metamail.c	Thu Feb 17 02:57:19 1994
3
--- /usr/ports/mail/metamail/work/mm2.7/src/metamail/metamail.c	Sat Dec 16 22:21:45 2006
4
***************
5
*** 20,25 ****
6
--- 20,27 ----
7
  
8
   ******************************************************* */
9
  #include <stdio.h>
10
+ #include <stdlib.h>
11
+ #include <string.h>
12
  #include <ctype.h>
13
  #include <sys/types.h>
14
  #include <sys/stat.h>
15
***************
16
*** 83,89 ****
17
  #define MAX_FILE_NAME_SIZE 256
18
  #define WRITE_BINARY	"w"
19
  #else /* AMIGA */
20
! extern char **environ, *gets();
21
  #define CATCOMMAND  "cat"
22
  #define CATTEMPLATE "cat %s"
23
  #define METAMAIL    "metamail"
24
--- 85,91 ----
25
  #define MAX_FILE_NAME_SIZE 256
26
  #define WRITE_BINARY	"w"
27
  #else /* AMIGA */
28
! extern char **environ;
29
  #define CATCOMMAND  "cat"
30
  #define CATTEMPLATE "cat %s"
31
  #define METAMAIL    "metamail"
32
***************
33
*** 100,105 ****
34
--- 102,108 ----
35
  #define CMDSIZE 1200 /* Maximum size of command to execute */
36
  
37
  #define LINE_BUF_SIZE       2000
38
+ #if 0
39
  #ifndef MICROSOFT
40
  extern char *malloc();
41
  extern char *realloc();
42
***************
43
*** 107,116 ****
44
  extern char *getenv();
45
  extern char *index();
46
  extern char *rindex();
47
  char fileToDelete[MAX_FILE_NAME_SIZE];
48
  
49
  char *FindParam();
50
- extern FILE *popen();
51
  static char *nomem = "Out of memory!";
52
  static char *mmversion = MM_VERSTRING;
53
  static char *NoAskDefault = "text,text/plain,text/richtext";
54
--- 110,121 ----
55
  extern char *getenv();
56
  extern char *index();
57
  extern char *rindex();
58
+ extern FILE *popen();
59
+ #endif
60
+ 
61
  char fileToDelete[MAX_FILE_NAME_SIZE];
62
  
63
  char *FindParam();
64
  static char *nomem = "Out of memory!";
65
  static char *mmversion = MM_VERSTRING;
66
  static char *NoAskDefault = "text,text/plain,text/richtext";
67
***************
68
*** 540,545 ****
69
--- 545,551 ----
70
                      ans = 2;
71
                  } else {
72
                      printf("\nWhat do you want to do with the %s data?\n1 -- See it as text\n2 -- Write it to a file\n3 -- Just skip it\n\n", octetstream ? "raw" : ContentType);
73
+                     *Fname = '\0';
74
                      fgets(Fname, sizeof(Fname), stdin);
75
                      ans = atoi(Fname);
76
                  }
77
***************
78
*** 554,561 ****
79
                              needname = 0;
80
                              printf("Please enter the name of a file to which the data should be written\n(Default: %s) > ", suggestedname);
81
                              fflush(stdout);
82
                              fgets(Fname, sizeof(Fname), stdin);
83
!                             Fname[strlen(Fname) - 1] = '\0'; /* bogus newline */
84
  #if !defined(AMIGA) && !defined(MSDOS)
85
                              if (!Fname[0]) strcpy(Fname, suggestedname);
86
                              if (Fname[0] == '~' && Fname[1] == '/') {
87
--- 560,569 ----
88
                              needname = 0;
89
                              printf("Please enter the name of a file to which the data should be written\n(Default: %s) > ", suggestedname);
90
                              fflush(stdout);
91
+                             *Fname = '\0';
92
                              fgets(Fname, sizeof(Fname), stdin);
93
!                             if (*Fname)
94
!                                 Fname[strlen(Fname) - 1] = '\0'; /* bogus newline */
95
  #if !defined(AMIGA) && !defined(MSDOS)
96
                              if (!Fname[0]) strcpy(Fname, suggestedname);
97
                              if (Fname[0] == '~' && Fname[1] == '/') {
98
***************
99
*** 579,588 ****
100
                                  int overwriteans = -1;
101
                                  do {
102
                                      printf("File %s exists.  Do you want to overwrite it (y/n) ?\n", Fname);
103
!                                     s = gets(AnsBuf);
104
                                      if (!s) {
105
                                          overwriteans = 0;
106
                                      } else {
107
                                          while (s && *s && isspace((unsigned char) *s)) ++s;
108
                                          if (*s == 'y' || *s == 'Y' || !*s || *s == '\n') {
109
                                              overwriteans = 1;
110
--- 587,598 ----
111
                                  int overwriteans = -1;
112
                                  do {
113
                                      printf("File %s exists.  Do you want to overwrite it (y/n) ?\n", Fname);
114
!                                     *AnsBuf = '\0';
115
!                                     s = fgets(AnsBuf, sizeof(AnsBuf), stdin);
116
                                      if (!s) {
117
                                          overwriteans = 0;
118
                                      } else {
119
+                                         s[strlen(s) - 1] = '\0';
120
                                          while (s && *s && isspace((unsigned char) *s)) ++s;
121
                                          if (*s == 'y' || *s == 'Y' || !*s || *s == '\n') {
122
                                              overwriteans = 1;
123
***************
124
*** 1202,1210 ****
125
      fprintf(outfp, "Content-type: %s", ContentType);
126
      for (j=0; j<CParamsUsed; ++j) {
127
          fprintf(outfp, " ; ");
128
!         fprintf(outfp, CParams[j]);
129
          fprintf(outfp, " = ");
130
!         fprintf(outfp, CParamValues[j]);
131
      }
132
      fprintf(outfp, "\n\n"); 
133
      TranslateInputToOutput(InputFP, outfp, EncodingCode, ContentType);
134
--- 1212,1220 ----
135
      fprintf(outfp, "Content-type: %s", ContentType);
136
      for (j=0; j<CParamsUsed; ++j) {
137
          fprintf(outfp, " ; ");
138
!         fprintf(outfp, "%s", CParams[j]);
139
          fprintf(outfp, " = ");
140
!         fprintf(outfp, "%s", CParamValues[j]);
141
      }
142
      fprintf(outfp, "\n\n"); 
143
      TranslateInputToOutput(InputFP, outfp, EncodingCode, ContentType);
144
***************
145
*** 1823,1830 ****
146
          } else {
147
              printf("This message contains '%s'-format data.\nDo you want to view it using the '%s' command (y/n) [y] ? ", ctype, ShortCommand(progname));
148
          }
149
!         s = gets(AnsBuf);
150
          if (!s) return(0); /* EOF */
151
  	while (s && *s && isspace((unsigned char) *s)) ++s;
152
  	if (*s == 'y' || *s == 'Y' || !*s || *s == '\n') return(1);
153
  	if (*s == 'n' || *s == 'N' || *s == 'q' || *s == 'Q') {
154
--- 1833,1841 ----
155
          } else {
156
              printf("This message contains '%s'-format data.\nDo you want to view it using the '%s' command (y/n) [y] ? ", ctype, ShortCommand(progname));
157
          }
158
!         s = fgets(AnsBuf, sizeof(AnsBuf), stdin);
159
          if (!s) return(0); /* EOF */
160
+         s[strlen(s) - 1] = '\0';
161
  	while (s && *s && isspace((unsigned char) *s)) ++s;
162
  	if (*s == 'y' || *s == 'Y' || !*s || *s == '\n') return(1);
163
  	if (*s == 'n' || *s == 'N' || *s == 'q' || *s == 'Q') {
164
***************
165
*** 2022,2028 ****
166
      if (lc2strcmp(charset, PrevCharset)) {
167
          char *s2, *charsetinuse;
168
  
169
!         strcpy(PrevCharset, charset);
170
          for (s2=PrevCharset; *s2; ++s2) {
171
              if (isupper((unsigned char) *s2)) *s2 = tolower((unsigned char) *s2);
172
          }
173
--- 2033,2040 ----
174
      if (lc2strcmp(charset, PrevCharset)) {
175
          char *s2, *charsetinuse;
176
  
177
!         strncpy(PrevCharset, charset, sizeof(PrevCharset));
178
!         PrevCharset[sizeof(PrevCharset) - 1] = '\0';
179
          for (s2=PrevCharset; *s2; ++s2) {
180
              if (isupper((unsigned char) *s2)) *s2 = tolower((unsigned char) *s2);
181
          }
182
***************
183
*** 2032,2038 ****
184
          }
185
      }
186
      if (ecode == ENCODING_NONE) {
187
!         printf(txt+1);
188
      } else {
189
          /* What follows is REALLY bogus, but all my encoding stuff is pipe-oriented right now... */
190
          MkTmpFileName(TmpFile);
191
--- 2044,2050 ----
192
          }
193
      }
194
      if (ecode == ENCODING_NONE) {
195
!         printf("%s", txt+1);
196
      } else {
197
          /* What follows is REALLY bogus, but all my encoding stuff is pipe-oriented right now... */
198
          MkTmpFileName(TmpFile);
199
Only in /usr/ports/mail/metamail/work/mm2.7/src/metamail: metamail.c.orig
200
Only in /usr/ports/mail/metamail/work/mm2.7/src/metamail: metamail.o
201
Only in /usr/ports/mail/metamail/work/mm2.7/src/metamail: mmencode
(-)../metamail.new/files/patch-al (+15 lines)
Line 0 Link Here
1
diff -rc ./metamail/mmencode.c /usr/ports/mail/metamail/work/mm2.7/src/metamail/mmencode.c
2
*** ./metamail/mmencode.c	Wed Jan 26 19:47:37 1994
3
--- /usr/ports/mail/metamail/work/mm2.7/src/metamail/mmencode.c	Sat Dec 16 22:21:45 2006
4
***************
5
*** 13,18 ****
6
--- 13,19 ----
7
  WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES.
8
  */
9
  #include <stdio.h>
10
+ #include <stdlib.h>
11
  #include <config.h>
12
  #ifdef MSDOS
13
  #include <fcntl.h>
14
Only in /usr/ports/mail/metamail/work/mm2.7/src/metamail: mmencode.c.orig
15
Only in /usr/ports/mail/metamail/work/mm2.7/src/metamail: mmencode.o
(-)../metamail.new/files/patch-am (+16 lines)
Line 0 Link Here
1
diff -rc ./metamail/putenv.c /usr/ports/mail/metamail/work/mm2.7/src/metamail/putenv.c
2
*** ./metamail/putenv.c	Tue Oct 12 17:17:43 1993
3
--- /usr/ports/mail/metamail/work/mm2.7/src/metamail/putenv.c	Sat Dec 16 22:21:45 2006
4
***************
5
*** 17,22 ****
6
--- 17,24 ----
7
  Cambridge, MA 02139, USA.  */
8
  
9
  #include <config.h>
10
+ #include <stdlib.h>
11
+ #include <string.h>
12
  #include <sys/types.h>
13
  #include <errno.h>
14
  #ifdef STDC_HEADERS
15
Only in /usr/ports/mail/metamail/work/mm2.7/src/metamail: putenv.c.orig
16
Only in /usr/ports/mail/metamail/work/mm2.7/src/metamail: putenv.o
(-)../metamail.new/files/patch-an (+24 lines)
Line 0 Link Here
1
diff -rc ./metamail/shared.c /usr/ports/mail/metamail/work/mm2.7/src/metamail/shared.c
2
*** ./metamail/shared.c	Sun May 16 20:19:32 1993
3
--- /usr/ports/mail/metamail/work/mm2.7/src/metamail/shared.c	Sat Dec 16 22:21:45 2006
4
***************
5
*** 1,4 ****
6
--- 1,6 ----
7
  #include <stdio.h>
8
+ #include <stdlib.h>
9
+ #include <string.h>
10
  #include <ctype.h>
11
  #include <config.h>
12
  #ifdef SYSV
13
***************
14
*** 6,12 ****
15
  #include <sys/utsname.h>
16
  #endif
17
  
18
- extern char *malloc();
19
  char **Exceptions;
20
  int *NeedsPortableNewlines;
21
  int ExceptionsAlloced = 0, ExceptionsUsed = 0;
22
--- 8,13 ----
23
Only in /usr/ports/mail/metamail/work/mm2.7/src/metamail: shared.c.orig
24
Only in /usr/ports/mail/metamail/work/mm2.7/src/metamail: shared.o
(-)../metamail.new/files/patch-ao (+110 lines)
Line 0 Link Here
1
diff -rc ./metamail/splitmail.c /usr/ports/mail/metamail/work/mm2.7/src/metamail/splitmail.c
2
*** ./metamail/splitmail.c	Mon Jan 31 23:23:14 1994
3
--- /usr/ports/mail/metamail/work/mm2.7/src/metamail/splitmail.c	Sat Dec 16 22:22:12 2006
4
***************
5
*** 21,26 ****
6
--- 21,28 ----
7
   ******************************************************* */
8
  
9
  #include <stdio.h>
10
+ #include <stdlib.h>
11
+ #include <string.h>
12
  #include <sys/types.h>
13
  #include <sys/stat.h>
14
  #include <config.h>
15
***************
16
*** 28,34 ****
17
  #include <time.h>
18
  
19
  #define MINCHUNKSIZE 20000 /* Better be enough to hold the headers, or we die! */
20
! extern char *malloc(), *index(), *getmyname();
21
  
22
  #ifdef AMIGA
23
  #define Prototype   extern
24
--- 30,36 ----
25
  #include <time.h>
26
  
27
  #define MINCHUNKSIZE 20000 /* Better be enough to hold the headers, or we die! */
28
! extern char *getmyname();
29
  
30
  #ifdef AMIGA
31
  #define Prototype   extern
32
***************
33
*** 41,48 ****
34
  #define VERBOSEDELIVERYCMD VerboseDeliveryCmd
35
  #else
36
  extern char *getenv();
37
! #define NORMALDELIVERYCMD "/usr/lib/sendmail -t -oi"
38
! #define VERBOSEDELIVERYCMD "/usr/lib/sendmail -t -v -oi"
39
  #endif
40
  
41
  usageexit() {
42
--- 43,50 ----
43
  #define VERBOSEDELIVERYCMD VerboseDeliveryCmd
44
  #else
45
  extern char *getenv();
46
! #define NORMALDELIVERYCMD "/usr/sbin/sendmail -t -oi"
47
! #define VERBOSEDELIVERYCMD "/usr/sbin/sendmail -t -v -oi"
48
  #endif
49
  
50
  usageexit() {
51
***************
52
*** 194,200 ****
53
  	s = endofheader(from);  /* would be index(from, '\n'),
54
  				 but need to check for continuation lines */
55
          *s = '\0';
56
! 	if (ShareThisHeader(from, SubjectBuf, &OrigID)) {
57
  	    strcat(SharedHeaders, from);
58
  	    strcat(SharedHeaders, "\n");
59
  	}
60
--- 196,202 ----
61
  	s = endofheader(from);  /* would be index(from, '\n'),
62
  				 but need to check for continuation lines */
63
          *s = '\0';
64
! 	if (ShareThisHeader(from, SubjectBuf, sizeof(SubjectBuf), &OrigID)) {
65
  	    strcat(SharedHeaders, from);
66
  	    strcat(SharedHeaders, "\n");
67
  	}
68
***************
69
*** 339,347 ****
70
      NULL
71
  };
72
  
73
! ShareThisHeader(s, SubjectBuf, OrigID)
74
  char *s;
75
  char *SubjectBuf;
76
  char **OrigID;
77
  {
78
      int i;
79
--- 341,350 ----
80
      NULL
81
  };
82
  
83
! ShareThisHeader(s, SubjectBuf, size, OrigID)
84
  char *s;
85
  char *SubjectBuf;
86
+ size_t size;
87
  char **OrigID;
88
  {
89
      int i;
90
***************
91
*** 361,367 ****
92
      }
93
      if (!ULstrcmp(s, "subject")) {
94
          *colon = ':';
95
!         strcpy(SubjectBuf, ++colon);
96
          return(0);
97
      }
98
      if (!ULstrcmp(s, "content-type")) {
99
--- 364,371 ----
100
      }
101
      if (!ULstrcmp(s, "subject")) {
102
          *colon = ':';
103
!         strncpy(SubjectBuf, ++colon, size);
104
!         SubjectBuf[size - 1] = '\0';
105
          return(0);
106
      }
107
      if (!ULstrcmp(s, "content-type")) {
108
Only in /usr/ports/mail/metamail/work/mm2.7/src/metamail: splitmail.c.orig
109
Only in /usr/ports/mail/metamail/work/mm2.7/src/metamail: splitmail.c~
110
Only in /usr/ports/mail/metamail/work/mm2.7/src/metamail: uue.o
(-)../metamail.new/files/patch-ap (+14 lines)
Line 0 Link Here
1
diff -rc ./richmail/richlex.c /usr/ports/mail/metamail/work/mm2.7/src/richmail/richlex.c
2
*** ./richmail/richlex.c	Thu Feb  3 03:29:37 1994
3
--- /usr/ports/mail/metamail/work/mm2.7/src/richmail/richlex.c	Sat Dec 16 22:21:45 2006
4
***************
5
*** 42,47 ****
6
--- 42,48 ----
7
  -------------------------------------------------------------------------*/
8
  
9
  #include <stdio.h>
10
+ #include <string.h>
11
  #include <ctype.h>
12
  #include "richlex.h"
13
  #include "richset.h"
14
Only in /usr/ports/mail/metamail/work/mm2.7/src/richmail: richlex.c.orig
(-)../metamail.new/files/patch-aq (+14 lines)
Line 0 Link Here
1
diff -rc ./richmail/richset.c /usr/ports/mail/metamail/work/mm2.7/src/richmail/richset.c
2
*** ./richmail/richset.c	Wed Oct 21 19:04:19 1992
3
--- /usr/ports/mail/metamail/work/mm2.7/src/richmail/richset.c	Sat Dec 16 22:21:45 2006
4
***************
5
*** 34,39 ****
6
--- 34,40 ----
7
  -------------------------------------------------------------------------*/
8
  
9
  #include <stdio.h>
10
+ #include <stdlib.h>
11
  #include "richlex.h"
12
  #include "richset.h"
13
  
14
Only in /usr/ports/mail/metamail/work/mm2.7/src/richmail: richset.c.orig
(-)../metamail.new/files/patch-ar (+53 lines)
Line 0 Link Here
1
diff -rc ./richmail/richtext.c /usr/ports/mail/metamail/work/mm2.7/src/richmail/richtext.c
2
*** ./richmail/richtext.c	Wed Feb  9 17:31:18 1994
3
--- /usr/ports/mail/metamail/work/mm2.7/src/richmail/richtext.c	Sat Dec 16 22:21:45 2006
4
***************
5
*** 14,19 ****
6
--- 14,21 ----
7
  */
8
  
9
  #include <stdio.h>
10
+ #include <stdlib.h>
11
+ #include <string.h>
12
  #include <ctype.h>
13
  #include <signal.h>
14
  #include "richlex.h"
15
***************
16
*** 155,160 ****
17
--- 157,172 ----
18
      exit(-1);
19
  #endif
20
  }
21
+ static lc2strcmp(s1, s2)
22
+ char *s1, *s2;
23
+ {
24
+     if (!s1 || !s2) return (-1);
25
+     while (*s1 && *s2) {
26
+ 	if (*s1 != *s2 && (tolower(*s1) != *s2)) return(-1);
27
+ 	++s1; ++s2;
28
+     }
29
+     return((*s1 == *s2) ? 0 : -1);
30
+ }
31
  
32
  #ifndef	RICHTEXT_LIBRARY
33
  
34
***************
35
*** 989,1004 ****
36
      while(*s) (*RichtextPutc)((int)(*s++),fp);
37
  }
38
  
39
- static lc2strcmp(s1, s2)
40
- char *s1, *s2;
41
- {
42
-     if (!s1 || !s2) return (-1);
43
-     while (*s1 && *s2) {
44
- 	if (*s1 != *s2 && (tolower(*s1) != *s2)) return(-1);
45
- 	++s1; ++s2;
46
-     }
47
-     return((*s1 == *s2) ? 0 : -1);
48
- }
49
  
50
  static lc2strncmp(s1, s2, len)
51
  char *s1, *s2;
52
--- 1001,1006 ----
53
Only in /usr/ports/mail/metamail/work/mm2.7/src/richmail: richtext.c.orig

Return to bug 106818