From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.ffmpeg.org (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTPS id 5E7204AC1C for ; Thu, 28 Aug 2025 19:01:40 +0000 (UTC) Authentication-Results: ffbox; dkim=fail (body hash mismatch (got b'dL/gbwM4aKPXDJIpDlsjJW3LjX3KYmOtBUu34BfDqMc=', expected b'4QfNukLHCwwwQSEN9MvnqPSW2m4zRRY9vIc55n8ufQA=')) header.d=gmail.com header.a=rsa-sha256 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ffmpeg.org; i=@ffmpeg.org; q=dns/txt; s=mail; t=1756407547; h=to : date : message-id : mime-version : reply-to : subject : list-id : list-archive : list-archive : list-help : list-owner : list-post : list-subscribe : list-unsubscribe : from : cc : content-type : content-transfer-encoding : from; bh=1kHaHQx4lRnToCbgAApYX4HwMSYtHZAj2pmCMux0TTo=; b=gwvY1fi9PlirMEvNXm2+oOngzYox7GCzX6SS3NUB9dYOOcXrRJEwRfO5WZpF9VZ0N6cOu SNcR3MlXq6HB7QtntFsugZ1Ren6iMYfvMsdV78R9M/n2qATP5QyTSWBKL+Sf1YTybVwd8yI nvJpR46UkY3o9qTph8wRRHfj5FU21oWMTJB5kNq1rIQI2lxb89u0c44LSSWwX4s7gdHbihJ jxbEc95Tn7lKcpn0wt6wVBfsdtvaG+N/Dk7+MXd1YnK6+fdNsgb/O2XFGy6zTNpqu0AyQhR LHZFqRrQbxrP2QE0f91Rpezpwcss6DM9GfJVW5RKTqZIVzMSfSf2dhBqMYMg== Received: from [172.19.0.4] (unknown [172.19.0.4]) by ffbox0-bg.ffmpeg.org (Postfix) with ESMTP id 955F568E7AD; Thu, 28 Aug 2025 21:59:07 +0300 (EEST) ARC-Seal: i=1; cv=none; a=rsa-sha256; d=ffmpeg.org; s=arc; t=1756407521; b=FBoxtRJH1t0/WL2yEi4507LTvFtujci+PKbePq9/8n2eUY6vW1gma2nweN6lb71raWdmS o9DWJEUfnxk++1vfQ3ymL41lemn0w8R5IpLa2Hsxz8V/qZIddmkMRZhH29JRCRtDUIE5igW tiOB4ams05XzveMlVKyDQt6CmCnDqSDNxz1+jWQpPUY6aBExcbWmh6FJS1HfGf9hTf+mG5b XiJzUpIdBDnk5/0K3Y7w5RwEcJ+888WivAWvADHdyYvjb/da8CXuBLeBhwoN0cPjSbqqn+8 ulSwELO1octgDqpJCaJyW498NCtoM7krNb8KWYZXtFKtSHrTxe4Y0a2etepg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=ffmpeg.org; s=arc; t=1756407521; h=from : sender : reply-to : subject : date : message-id : to : cc : mime-version : content-type : content-transfer-encoding : content-id : content-description : resent-date : resent-from : resent-sender : resent-to : resent-cc : resent-message-id : in-reply-to : references : list-id : list-help : list-unsubscribe : list-subscribe : list-post : list-owner : list-archive; bh=dL/gbwM4aKPXDJIpDlsjJW3LjX3KYmOtBUu34BfDqMc=; b=FdDLInmQ43FA9sSKw1VL0WIW5jt90qbTZxftBb00frOwjYdiTF/aQLeEAdBl1tMm83Tit DEdKMgNvlxwVGYaJjAn+wHLT3crCwbWQpTl0Q5vKJBXqiQrQoIR2HRebWblKa0Sk3CgNvzG /MOUDylrDN+daHpcUWL5QEg2qec6dyWLb6FJ9Hf+OWzQ1nlpe1R2aPz2ZaxMGV6jt+w33uO 5FN8n/e7zfFkVia2Jcwcxmb3SrWVapdXF7JnOAUDU9lucl+x3V+UV5iiRgPSspGyd9svwfn Xvr7vqZN7R1RUqxAKq5cTwBMLrXzFe9SitFruKjq4RRY/OKpT5WH+DoUXVoQ== ARC-Authentication-Results: i=1; ffmpeg.org; dkim=pass header.d=gmail.com; arc=none; dmarc=pass header.from=gmail.com policy.dmarc=quarantine Authentication-Results: ffmpeg.org; dkim=pass header.d=gmail.com; arc=none (Message is not ARC signed); dmarc=pass (Used From Domain Record) header.from=gmail.com policy.dmarc=quarantine Received: from mail-pj1-f45.google.com (mail-pj1-f45.google.com [209.85.216.45]) by ffbox0-bg.ffmpeg.org (Postfix) with ESMTPS id A1E446801AA for ; Thu, 28 Aug 2025 21:58:26 +0300 (EEST) Received: by mail-pj1-f45.google.com with SMTP id 98e67ed59e1d1-324e6daaa39so1290147a91.0 for ; Thu, 28 Aug 2025 11:58:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1756407504; x=1757012304; darn=ffmpeg.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=4QfNukLHCwwwQSEN9MvnqPSW2m4zRRY9vIc55n8ufQA=; b=Kqi82+x2m/+6z9AJ4J/5fs/HQJGkhEvuIwxjG+/BxZSFAKL4ExCeag8rLJkvilMOlO faTqYAViS8k8ouoQwAAYdkgkwzD8DjN3EQFp+AiEdrGFnWQhezMKpwzAGpdg4B1K48Yj k3dvy/xTmwMVO64edqA7lp8C1XUCPBgAAoE13NqYSWMdJqBpmb4Nz0hc4VA5H4aymCXr ZL1kFwRZIoppBOwzDG1vUiiWnPF731sMDprz64b6LaSMNAGbLjHW0UxX2kGCfl4P2aIP hMRPortoAUXXoLRFb0xqBDEfh1IJa7vyoPXDXeIVOEYywXp7n3wxGVeqPNeQeoyhVdGh 3XsA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1756407504; x=1757012304; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=4QfNukLHCwwwQSEN9MvnqPSW2m4zRRY9vIc55n8ufQA=; b=d967fvd2rmaXS0M4Hz3PclhAaxLDKAEDtvlht72TZGSytZe/4j9zdimpvEjZmbaH8c RQOQHDu9L642xCaBsHZedQSJ9ARPxdkuCssZUh0UPLviTdqho86i9xilXGiFvXlu4Lb/ JYAnxEJ3oj9+B4eXx2dRDu+K2p0hW+CvszCkQdTZhuXy8b3jX88upQfxAcJRAtxXbNML 8m4HQ3iykBC4Ok86arpPqTbkFKgBSOtlpyt+99Eq8jPq4omz0xr7Php7HaUwyU5NGrRY zZ8pOMtJI2piMLB38qdx5zu1PoSaum/3W4LocNs28nm4VhVv68xY4AGi/lRHIiFku5+O Xktw== X-Gm-Message-State: AOJu0Yxdfo7gzIGBAN3DAeqH5276R/wSROA6Oc0WVMHY36tKWA2pQhcU n5yNsEUKdvuL8CtEgBRmpv87jogq+Ujr+LtutLMHidJd/30auhMa6gNVNNaeiA== X-Gm-Gg: ASbGncsqfnWk9ZbROZyKZfhRRTF0/kiYMVpWo2GU4GmmZhvuL2gMTYpEUUwu0uj/rWb MxLuZjhGOkHzzlXix2T/UlZc4ObizlNQtBLLhVSNQlKYKbQbW0HtBlFzbxAI+RFvP+YkbH7DoxV MlyX16CgTgpMhsP3RMAjI+ooB1YEn9Wn0jLMT0seKd1sTJ9HFU6MNGXDt72ISwESqLNlomWkUH0 BR2/1jKAE4h5shJPgnftkTq9KR6OHJVjpvWxGAV+sclOBUOgS056gOYTkdjTZX/KzOb2JEKGoSL nbycY6QcT6uCpQpHxfl2JJArAf5UrmBYCG7aLwPezA03a7BXzvJFWLwb8au1IUDcUXAH6bdvNAR fHX/bl5N7Pcsa4kNoCrA4d8tbqQ== X-Google-Smtp-Source: AGHT+IFjyv+76Ecdj9K2Xy53KdxonzpRMnhsx7VDLrWXR6rg3spZcZne1xqcnC9o0EQX7ofM4UUdDg== X-Received: by 2002:a17:90b:2647:b0:327:4d35:fd71 with SMTP id 98e67ed59e1d1-3274d360417mr12158167a91.13.1756407504309; Thu, 28 Aug 2025 11:58:24 -0700 (PDT) Received: from pc.cnshub.home ([115.43.71.72]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-3274572be3bsm4620121a91.2.2025.08.28.11.58.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 28 Aug 2025 11:58:20 -0700 (PDT) To: ffmpeg-devel@ffmpeg.org Date: Fri, 29 Aug 2025 02:58:16 +0800 Message-ID: <20250828185816.2807112-1-mail6543210@gmail.com> X-Mailer: git-send-email 2.51.0 MIME-Version: 1.0 Message-ID-Hash: XD2LDHLPRAZCQE7AVQOFXPMJ6WHJFFKD X-Message-ID-Hash: XD2LDHLPRAZCQE7AVQOFXPMJ6WHJFFKD X-MailFrom: SRS0=YEEW=3I=gmail.com=mail6543210@ffmpeg.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; header-match-ffmpeg-devel.ffmpeg.org-0; header-match-ffmpeg-devel.ffmpeg.org-1; header-match-ffmpeg-devel.ffmpeg.org-2; header-match-ffmpeg-devel.ffmpeg.org-3; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.10 Precedence: list Reply-To: FFmpeg development discussions and patches Subject: [FFmpeg-devel] [PATCH] fftools/ffmpeg: fix gracefully shutdown List-Id: FFmpeg development discussions and patches Archived-At: Archived-At: List-Archive: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: From: Patrick Wang via ffmpeg-devel Cc: Patrick Wang Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Archived-At: List-Archive: List-Post: d119ae2fd82a494d9430ff4d4fc262961a68c598 removed the loop-breaking condition received_sigterm. Thus, signals no longer gracefully shutdown ffmpeg. Fixes: #10834 Signed-off-by: Patrick Wang --- fftools/ffmpeg.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/fftools/ffmpeg.c b/fftools/ffmpeg.c index de607cac9..cd3894341 100644 --- a/fftools/ffmpeg.c +++ b/fftools/ffmpeg.c @@ -806,8 +806,6 @@ static int check_keyboard_interaction(int64_t cur_time) { int i, key; static int64_t last_time; - if (received_nb_signals) - return AVERROR_EXIT; /* read_key() returns 0 on EOF */ if (cur_time - last_time >= 100000) { key = read_key(); @@ -891,6 +889,9 @@ static int transcode(Scheduler *sch) while (!sch_wait(sch, stats_period, &transcode_ts)) { int64_t cur_time= av_gettime_relative(); + if (received_nb_signals) + break; + /* if 'q' pressed, exits */ if (stdin_interaction) if (check_keyboard_interaction(cur_time) < 0) -- 2.51.0 _______________________________________________ ffmpeg-devel mailing list -- ffmpeg-devel@ffmpeg.org To unsubscribe send an email to ffmpeg-devel-leave@ffmpeg.org