Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 18 Nov 2003 18:37:39 +0100 (CET)
From:      "Sebastian Yepes F.ESN" <esn@123.info>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/59426: [Fix Port]:: net/psi Fix the support of gpg 1.2.3
Message-ID:  <20031118173739.3EB9E17081@mail.x123.info>
Resent-Message-ID: <200311181740.hAIHeK4F050452@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         59426
>Category:       ports
>Synopsis:       [Fix Port]:: net/psi Fix the support of gpg 1.2.3
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Tue Nov 18 09:40:20 PST 2003
>Closed-Date:
>Last-Modified:
>Originator:     Sebastian Yepes F. [ESN]
>Release:        FreeBSD 5.1-CURRENT i386
>Organization:
>Environment:
System: FreeBSD agosto 5.1-CURRENT FreeBSD 5.1-CURRENT #1: Tue Jul 22 15:14:38 GMT 2003 root@agosto:/usr/obj/usr/src/sys/MYK_SRV i386


	
>Description:
	Fix the Support of gpg 1.2.3 on the PSI
>How-To-Repeat:
	
>Fix:


diff -uN /dev/null psi/files/patch-aa
--- /dev/null	Thu Jan  1 01:00:00 1970
+++ psi/files/patch-aa	Tue Nov 18 18:26:26 2003
@@ -0,0 +1,58 @@
+diff -ur cutestuff.ori/openpgp/gpgop.cpp cutestuff/openpgp/gpgop.cpp
+--- cutestuff.ori/openpgp/gpgop.cpp	Tue Nov 18 18:07:55 2003
++++ cutestuff/openpgp/gpgop.cpp	Tue Nov 18 18:13:37 2003
+@@ -543,18 +543,33 @@
+ 		return false;
+ 
+ 	QStringList::ConstIterator it = lines.begin();
++	QString keyring;
++	int ver = 0;
+ 
+-	// first line is keyring file
+-	QString keyring = *(it++);
+-
+-	// skip past the divider
++	// check if gnupg version is 1.2.3 or below
+ 	for(; it != lines.end(); ++it) {
+-		if((*it).at(0) == '-')
+-			break;
++	   if((*it).at(0) == '-') {
++	      ver = 1;
++	      break;
++	   }
++	}
++	
++	it = lines.begin();
++
++	// if gnupg version is 1.2.2 and below first line is keyring
++	if(ver) {
++	   // first line is keyring file
++	   keyring = *(it++);
++
++	   // skip past the divider
++	   for(; it != lines.end(); ++it) {
++	      if((*it).at(0) == '-')
++		 break;
++	   }
++	   if(it == lines.end())
++	      return false;
++	   ++it;
+ 	}
+-	if(it == lines.end())
+-		return false;
+-	++it;
+ 
+ 	OpenPGP::Key *k = 0;
+ 	for(; it != lines.end(); ++it) {
+@@ -620,8 +635,9 @@
+ 
+ 	if(_keylist)
+ 		*_keylist = keyList;
+-	if(_keyring)
+-		*_keyring = keyring;
++	if(ver)
++	   if(_keyring)
++	      *_keyring = keyring;
+ 
+ 	return true;
+ }
>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20031118173739.3EB9E17081>