From b876d9b1c9ce58b8ba2440cf61bca7555a0dfb9b Mon Sep 17 00:00:00 2001
Message-ID: <b876d9b1c9ce58b8ba2440cf61bca7555a0dfb9b.1761453668.git.sam@gentoo.org>
From: Kerin Millar <kfm@plushkava.net>
Date: Sun, 26 Oct 2025 02:46:02 +0000
Subject: [PATCH] emerge-webrsync: restore the missing option-arg for curl
 --continue-at

The curl(1) user-agent supports a --continue-at option, which requires
an option-argument. Where the option-argument is <hyphen-dash>, curl
will automatically try to determine how to resume a transfer. Further,
emerge-webrsync forcibly injects the option if it detects that the value
of FETCHCOMMAND specifies a curl command.

However, the option-argument was unintentionally removed during a bout
of re-factoring and (otherwise unrelated) bug fixing. This went
unnoticed until now because wget is more commonly used. Restore it.

Fixes: f3af8263ce544750a9e9a155b1264d07a86677d4
Signed-off-by: Kerin Millar <kfm@plushkava.net>
Signed-off-by: Sam James <sam@gentoo.org>
---
 bin/emerge-webrsync | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/bin/emerge-webrsync b/bin/emerge-webrsync
index 53a3a12715..cca63ebb35 100755
--- a/bin/emerge-webrsync
+++ b/bin/emerge-webrsync
@@ -217,7 +217,7 @@ get_fetchcommand() {
 			fi
 			;;
 		curl)
-			opts="--continue-at -f -S"
+			opts="--continue-at - -f -S"
 			if (( opt[quiet] )); then
 				opts+=" -s"
 			fi
-- 
2.51.1

