summaryrefslogtreecommitdiff
path: root/archivers/unrar/patches/patch-consio.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'archivers/unrar/patches/patch-consio.cpp')
-rw-r--r--archivers/unrar/patches/patch-consio.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/archivers/unrar/patches/patch-consio.cpp b/archivers/unrar/patches/patch-consio.cpp
new file mode 100644
index 00000000000..29b60312413
--- /dev/null
+++ b/archivers/unrar/patches/patch-consio.cpp
@@ -0,0 +1,15 @@
+$NetBSD: patch-consio.cpp,v 1.1 2011/12/09 13:51:56 hans Exp $
+
+Use getpassphrase(3C) on SunOS to allow passwords longer than 8 chars.
+
+--- consio.cpp.orig 2011-03-02 08:43:12.000000000 +0100
++++ consio.cpp 2011-12-09 14:38:05.903683508 +0100
+@@ -129,6 +129,8 @@ void GetPasswordText(wchar *Str,uint Max
+ char StrA[MAXPASSWORD];
+ #if defined(_EMX) || defined(_BEOS) || defined(__sparc) || defined(sparc) || defined (__VMS)
+ fgets(StrA,ASIZE(StrA)-1,stdin);
++#elif defined(__sun)
++ strncpyz(StrA,getpassphrase(""),ASIZE(StrA));
+ #else
+ strncpyz(StrA,getpass(""),ASIZE(StrA));
+ #endif