From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 82FAA13824A for ; Sun, 8 May 2016 21:21:23 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 4380521C093; Sun, 8 May 2016 21:21:20 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 7A39221C079 for ; Sun, 8 May 2016 21:21:19 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id A4EEE340BCB for ; Sun, 8 May 2016 21:21:18 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 3E56B968 for ; Sun, 8 May 2016 21:21:15 +0000 (UTC) From: "Brian Dolbec" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Brian Dolbec" Message-ID: <1462742322.b1a831bffd28fc1bb889cc90bb7690c7e5e2b8d9.dolsen@gentoo> Subject: [gentoo-commits] proj/portage:repoman commit in: pym/repoman/modules/scan/metadata/ X-VCS-Repository: proj/portage X-VCS-Files: pym/repoman/modules/scan/metadata/pkgmetadata.py X-VCS-Directories: pym/repoman/modules/scan/metadata/ X-VCS-Committer: dolsen X-VCS-Committer-Name: Brian Dolbec X-VCS-Revision: b1a831bffd28fc1bb889cc90bb7690c7e5e2b8d9 X-VCS-Branch: repoman Date: Sun, 8 May 2016 21:21:15 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: f8707e75-52fe-41b6-a5cd-df0decbc6e22 X-Archives-Hash: 2dfbd567959c7bf55f0140fe367a3cfb commit: b1a831bffd28fc1bb889cc90bb7690c7e5e2b8d9 Author: Brian Dolbec gentoo org> AuthorDate: Wed May 4 06:08:50 2016 +0000 Commit: Brian Dolbec gentoo org> CommitDate: Sun May 8 21:18:42 2016 +0000 URL: https://gitweb.gentoo.org/proj/portage.git/commit/?id=b1a831bf repoman/modules/.../pkgmetadata.py: Fix failed missing doctype detection The docinfo is always created, so is not valid to use like a boolean to detect a missing doctype. doctype is a null string or equivalent and as such the correct choice for the if statement. Failure discoverd by: Göktürk Yüksek binghamton.edu> Thank you pym/repoman/modules/scan/metadata/pkgmetadata.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pym/repoman/modules/scan/metadata/pkgmetadata.py b/pym/repoman/modules/scan/metadata/pkgmetadata.py index 83ca93f..d8344c2 100644 --- a/pym/repoman/modules/scan/metadata/pkgmetadata.py +++ b/pym/repoman/modules/scan/metadata/pkgmetadata.py @@ -106,7 +106,7 @@ class PkgMetadata(ScanBase, USEFlagChecks): "xml declaration encoding should be '%s', not '%s'" % (xpkg, metadata_xml_encoding, xml_encoding)) - if not _metadata_xml.docinfo: + if not _metadata_xml.docinfo.doctype: metadata_bad = True self.qatracker.add_error( "metadata.bad",