SHA256
1
0
forked from pool/rpmlint
rpmlint/suse-url-check.diff
OBS User autobuild 4d4e6f73c7 Accepting request 50483 from Base:System
Copy from Base:System/rpmlint based on submit request 50483 from user prusnak

OBS-URL: https://build.opensuse.org/request/show/50483
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/rpmlint?expand=0&rev=68
2010-10-14 12:32:03 +00:00

22 lines
1.1 KiB
Diff

Index: TagsCheck.py
===================================================================
--- TagsCheck.py.orig
+++ TagsCheck.py
@@ -762,14 +762,14 @@ class TagsCheck(AbstractCheck.AbstractCh
if not valid_license:
self._unexpanded_macros(pkg, 'License', rpm_license)
- for tag in ('URL', 'DistURL', 'BugURL'):
+ for tag in ('URL', 'BugURL'):
if hasattr(rpm, 'RPMTAG_%s' % tag.upper()):
url = pkg[getattr(rpm, 'RPMTAG_%s' % tag.upper())]
self._unexpanded_macros(pkg, tag, url, is_url = True)
if url:
(scheme, netloc) = urlparse(url)[0:2]
if not scheme or not netloc or "." not in netloc or \
- scheme not in ('http', 'https', 'ftp') or \
+ scheme not in ('obs', 'http', 'https', 'ftp') or \
(Config.getOption('InvalidURL') and \
invalid_url_regex.search(url)):
printWarning(pkg, 'invalid-url', tag, url)