Tue Sep 29 17:10:38 2009 UTC ()
Fix build on systems with native getline() function.
>From Anon.


(wiz)
diff -r1.6 -r1.7 pkgsrc/security/pgp2/distinfo
diff -r0 -r1.1 pkgsrc/security/pgp2/patches/patch-ai

cvs diff -r1.6 -r1.7 pkgsrc/security/pgp2/distinfo (expand / switch to unified diff)

--- pkgsrc/security/pgp2/distinfo 2006/09/28 16:21:46 1.6
+++ pkgsrc/security/pgp2/distinfo 2009/09/29 17:10:38 1.7
@@ -1,13 +1,14 @@ @@ -1,13 +1,14 @@
1$NetBSD: distinfo,v 1.6 2006/09/28 16:21:46 tron Exp $ 1$NetBSD: distinfo,v 1.7 2009/09/29 17:10:38 wiz Exp $
2 2
3SHA1 (pgp263is.tar.gz) = 031e061ba1d62d7db35f1f854c489867e88f421d 3SHA1 (pgp263is.tar.gz) = 031e061ba1d62d7db35f1f854c489867e88f421d
4RMD160 (pgp263is.tar.gz) = b1cba2be918cecc8b9062272d43626c8876fa7f4 4RMD160 (pgp263is.tar.gz) = b1cba2be918cecc8b9062272d43626c8876fa7f4
5Size (pgp263is.tar.gz) = 607982 bytes 5Size (pgp263is.tar.gz) = 607982 bytes
6SHA1 (patch-aa) = 740486e879c161041969fedebc565dd7683c277c 6SHA1 (patch-aa) = 740486e879c161041969fedebc565dd7683c277c
7SHA1 (patch-ab) = d210fadf6ef45ecce20381174ec1b55615dc3490 7SHA1 (patch-ab) = d210fadf6ef45ecce20381174ec1b55615dc3490
8SHA1 (patch-ac) = 32e69f1335c3aa7b974dc7fa4100d1f9ebf358ec 8SHA1 (patch-ac) = 32e69f1335c3aa7b974dc7fa4100d1f9ebf358ec
9SHA1 (patch-ad) = 93f72f3e4f91f478429da8fda4671e171eb167ac 9SHA1 (patch-ad) = 93f72f3e4f91f478429da8fda4671e171eb167ac
10SHA1 (patch-ae) = 307dddd61ef0ee3257a11822fc7bd423c5fd784f 10SHA1 (patch-ae) = 307dddd61ef0ee3257a11822fc7bd423c5fd784f
11SHA1 (patch-af) = 6f58d2b26a16886947f2e5681a672a7cf9979f42 11SHA1 (patch-af) = 6f58d2b26a16886947f2e5681a672a7cf9979f42
12SHA1 (patch-ag) = 377b17bc3783737c492708de57d6f4259e358a66 12SHA1 (patch-ag) = 377b17bc3783737c492708de57d6f4259e358a66
13SHA1 (patch-ah) = 15fe0597566ad8bf3123a54d3697e104e85ee425 13SHA1 (patch-ah) = 15fe0597566ad8bf3123a54d3697e104e85ee425
 14SHA1 (patch-ai) = 3afafb582e229e70721d7ee96d25d7d1d006d870

File Added: pkgsrc/security/pgp2/patches/patch-ai
$NetBSD: patch-ai,v 1.1 2009/09/29 17:10:38 wiz Exp $

--- armor.c.orig	1996-01-17 19:37:20.000000000 +0000
+++ armor.c
@@ -343,7 +343,7 @@ copyline(FILE * in, FILE * out)
  * idea.
  */
 static int
-getline(char *buf, int n, FILE * f)
+get_line(char *buf, int n, FILE * f)
 {
     int state;
     char *p;
@@ -376,7 +376,7 @@ getline(char *buf, int n, FILE * f)
 	    return 0;		/* Out of buffer space */
 	}
     }				/* for (;;) */
-}				/* getline */
+}				/* get_line */
 
 #if 1
 /* This limit is advisory only; longer lines are handled properly.
@@ -547,7 +547,7 @@ armor_file(char *infilename, char *outfi
 	    return 1;
 	}
 	fprintf(outFile, "-----BEGIN PGP SIGNED MESSAGE-----\n\n");
-	while ((i = getline(buffer, sizeof buffer, clearFile)) >= 0) {
+	while ((i = get_line(buffer, sizeof buffer, clearFile)) >= 0) {
 	    /* Quote lines beginning with '-' as per RFC1113;
 	     * Also quote lines beginning with "From "; this is
 	     * for Unix mailers which add ">" to such lines.
@@ -1231,7 +1231,7 @@ LANG("\n\007Unable to write ciphertext o
 	for (;;) {
 	    ++infile_line;
 	    nline = status;
-	    status = getline(buf, sizeof buf, in);
+	    status = get_line(buf, sizeof buf, in);
 	    if (status < 0) {
 		fprintf(pgpout,
 LANG("ERROR: ASCII armor decode input ended unexpectedly!\n"));
@@ -1249,7 +1249,7 @@ LANG("ERROR: ASCII armor decode input en
 	    /* Copy trailing part of line, if any. */
 	    if (!status)
 		status = copyline(in, litout);
-	    /* Ignore error; getline will discover it again */
+	    /* Ignore error; get_line will discover it again */
 	}
 	fflush(litout);
 	if (ferror(litout)) {