]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
mailbot: avoid octal bug
authorSasha Levin <sashal@kernel.org>
Fri, 23 May 2025 12:19:58 +0000 (08:19 -0400)
committerSasha Levin <sashal@kernel.org>
Fri, 23 May 2025 12:20:10 +0000 (08:20 -0400)
Signed-off-by: Sasha Levin <sashal@kernel.org>
scripts/mailbot.sh

index a04cfcdcb4aab13bb5cc7c9bede2c7c5d4372b18..2ca3a71a8f205feb4266c8b9d8a343dccaf0625b 100755 (executable)
@@ -290,6 +290,9 @@ extract_series_info() {
     if [[ $subject =~ $part_pattern ]]; then
         local current="${BASH_REMATCH[1]}"
         local total="${BASH_REMATCH[2]}"
+        # Remove leading zeros to avoid octal interpretation
+        current=$((10#$current))
+        total=$((10#$total))
         echo "$current $total"
         return 0
     fi