[OpenWrt-Devel] [PATCH] scripts/feeds: observe -p flag for preferential feeds

Felix Fietkau nbd at openwrt.org
Wed May 27 11:21:00 EDT 2015


On 2015-05-26 17:09, Karl Palsson wrote:
> From: Karl Palsson <karlp at remake.is>
> 
> lookup_target was trampling the $feed variable, resulting in the -p flag
> no longer preferentially installing from the named feed.
> 
> Signed-off-by: Karl Palsson <karlp at remake.is>
> ---
>  scripts/feeds | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/scripts/feeds b/scripts/feeds
> index a6be9cc..1330425 100755
> --- a/scripts/feeds
> +++ b/scripts/feeds
> @@ -450,10 +450,10 @@ sub install_package {
>  	my $force = shift;
>  	my $ret = 0;
>  
> -	$feed = lookup_target($feed, $name);
> -	$feed and do {
> +	$feed_target = lookup_target($feed, $name);
Well, with this change it is simply trampling a different (global)
variable, which is not a good idea either. How about making it use a
local variable instead?

- Felix
_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel



More information about the openwrt-devel mailing list