diff mbox

trivial: use geturischeme helper function where possible

Message ID 1b6f296fec701a154c75.1374236023@BEANTN0L019720
State Accepted
Commit 720ca65ce801d8a67f0aca98434b0e514e0c5a6d
Headers show

Commit Message

Thomas De Schampheleire July 19, 2013, 12:13 p.m. UTC
pkg-download.mk contains some helper functions to obtain subparts of URLs,
like the URI scheme. In pkg-generic.mk, there is still one opportunity to use
that helper function, instead of hardcoding it.

Signed-off-by: Thomas De Schampheleire <thomas.de.schampheleire@gmail.com>

---
 package/pkg-generic.mk |  2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

Comments

Peter Korsgaard July 21, 2013, 10:12 p.m. UTC | #1
>>>>> "Thomas" == Thomas De Schampheleire <patrickdepinguin+buildroot@gmail.com> writes:

 Thomas> pkg-download.mk contains some helper functions to obtain
 Thomas> subparts of URLs, like the URI scheme. In pkg-generic.mk, there
 Thomas> is still one opportunity to use that helper function, instead
 Thomas> of hardcoding it.

 Thomas> Signed-off-by: Thomas De Schampheleire <thomas.de.schampheleire@gmail.com>

Committed, thanks.
diff mbox

Patch

diff --git a/package/pkg-generic.mk b/package/pkg-generic.mk
--- a/package/pkg-generic.mk
+++ b/package/pkg-generic.mk
@@ -269,7 +269,7 @@  ifndef $(2)_SITE_METHOD
   $(2)_SITE_METHOD = $($(3)_SITE_METHOD)
  else
 	# Try automatic detection using the scheme part of the URI
-	$(2)_SITE_METHOD = $(firstword $(subst ://, ,$(call qstrip,$($(2)_SITE))))
+	$(2)_SITE_METHOD = $(call geturischeme,$($(2)_SITE))
  endif
 endif