Received: with ECARTIS (v1.0.0; list gopher); Wed, 17 Dec 2003 08:33:32 -0600 (CST) Return-Path: X-Original-To: gopher@complete.org Delivered-To: gopher@complete.org Received: from localhost (localhost [127.0.0.1]) by glockenspiel.complete.org (Postfix) with ESMTP id 8EB6EA2; Wed, 17 Dec 2003 08:33:31 -0600 (CST) Received: from gatekeeper.elmer.external.excelhustler.com (gatekeeper.excelhustler.com [68.99.114.105]) (using TLSv1 with cipher EDH-RSA-DES-CBC3-SHA (168/168 bits)) (Client CN "gatekeeper.elmer.external.excelhustler.com", Issuer "excelhustler.com" (not verified)) by glockenspiel.complete.org (Postfix) with ESMTP id 1426D80; Wed, 17 Dec 2003 08:33:30 -0600 (CST) Received: from chatterbox.elmer.internal.excelhustler.com (unknown [192.168.0.12]) (using TLSv1 with cipher EDH-RSA-DES-CBC3-SHA (168/168 bits)) (Client CN "chatterbox.elmer.internal.excelhustler.com", Issuer "excelhustler.com" (verified OK)) by gatekeeper.elmer.external.excelhustler.com (Postfix) with ESMTP id 19315E0189; Wed, 17 Dec 2003 08:33:27 -0600 (CST) Received: from localhost (localhost [127.0.0.1]) by chatterbox.elmer.internal.excelhustler.com (Postfix) with ESMTP id DDF0E5C009; Wed, 17 Dec 2003 08:33:26 -0600 (CST) Received: from wile.internal.excelhustler.com (wile.internal.excelhustler.com [192.168.1.34]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by chatterbox.elmer.internal.excelhustler.com (Postfix) with ESMTP id B5EE55C008; Wed, 17 Dec 2003 08:33:26 -0600 (CST) Received: by wile.internal.excelhustler.com (Postfix, from userid 1000) id 895B68B7E; Wed, 17 Dec 2003 08:33:26 -0600 (CST) Date: Wed, 17 Dec 2003 08:33:26 -0600 From: John Goerzen To: gopher@complete.org Subject: [gopher] Re: .names Message-ID: <20031217143326.GA14174@complete.org> References: <3FDFB66F.B5960867@hal3000.cx> Mime-Version: 1.0 Content-type: text/plain Content-Disposition: inline In-Reply-To: <3FDFB66F.B5960867@hal3000.cx> User-Agent: Mutt/1.4i X-Scanned-By: clamscan at chatterbox.elmer.internal.excelhustler.com X-Scanned-By: clamscan at complete.org Content-Transfer-Encoding: 8bit X-archive-position: 860 X-ecartis-version: Ecartis v1.0.0 Sender: gopher-bounce@complete.org Errors-to: gopher-bounce@complete.org X-original-sender: jgoerzen@complete.org Precedence: bulk Reply-to: gopher@complete.org List-help: List-unsubscribe: List-software: Ecartis version 1.0.0 List-Id: Gopher X-List-ID: Gopher List-subscribe: List-owner: List-post: List-archive: X-list: gopher On Tue, Dec 16, 2003 at 07:50:39PM -0600, Chris wrote: > under pygopherd it doesnt. OK, I think this is fixed. I have just uploaded PyGopherd 2.0.7. Or, you can apply the attached patch to your 2.0.6 installation. Let me know if it works for you. -- John -- Attached file included as plaintext by Ecartis -- Index: pygopherd/handlers/UMN.py =================================================================== --- pygopherd/handlers/UMN.py (revision 299) +++ pygopherd/handlers/UMN.py (working copy) @@ -151,6 +151,19 @@ for field in new.geteadict().keys(): old.setea(field, new.getea(field)) + def sortLinkEntries(self, x, y): + """Called by processLinkFile() to sort entries according to the + specified number.""" + xnum = x.getnum() + ynum = y.getnum() + if xnum == ynum: + return 0 + if xnum == None: + return -1 + if ynum == None: + return 1 + return cmp(xnum, ynum) + def processLinkFile(self, filename, capfilepath = None): """Processes a link file. If capfilepath is set, it should be the equivolent of the Path= in a .names file.""" @@ -162,6 +175,7 @@ linkentries.append(entry) if nextstep == 'stop': break + linkentries.sort(self.sortLinkEntries) return linkentries def getLinkItem(self, fd, capfilepath = None):