1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-11-15 23:50:44 +00:00
freebsd-ports/archivers/hpack.non-usa.only/files/patch-ab

30 lines
766 B
Plaintext
Raw Normal View History

--- crypt/keymgmt.c.orig Tue Aug 17 16:56:14 1993
+++ crypt/keymgmt.c Tue Dec 28 20:01:38 1999
@@ -495,11 +495,24 @@
FD keyFileFD, savedInFD = getInputFD();
BOOLEAN matched, firstTime = TRUE;
char *matchID, firstChar;
- char *keyFilePath;
+ char *keyFilePath, *s;
int userIDlength, i;
+#ifdef __UNIX__
+ char *h, buf[ MAX_PATH ];
+#endif
+ if ((s = getenv( PGPPATH )) == NULL)
+#ifdef __UNIX__
+ if ((h = getenv( "HOME" )) != NULL) {
+ strcpy(buf, h);
+ strcat(buf, "/.pgp");
+ s = buf;
+ }
+#else
+ ;
+#endif
/* Use the keyID to get the public key from a key file */
- keyFilePath = getFirstKeyPath( getenv( PGPPATH ), keyFileName );
+ keyFilePath = getFirstKeyPath( s, keyFileName );
while( keyFilePath != NULL )
{
/* Open key file */