[FFmpeg-devel] [PATCH] Support Ctrl+Break in ffmpeg.exe on Windows as if it was Ctrl+C
Michael Niedermayer
michaelni at gmx.at
Tue Jun 30 22:08:52 CEST 2015
On Tue, Jun 30, 2015 at 01:00:22PM -0600, Roger Pack wrote:
> On 6/30/15, Michael Niedermayer <michaelni at gmx.at> wrote:
> > On Mon, Jun 29, 2015 at 11:09:14PM -0600, Roger Pack wrote:
>
> > [...]
>
> >> + Sleep(0);
>
> >
>
> > the funky line ending is here
>
> OK try this one.
> thanks!
> configure | 2 ++
> ffmpeg.c | 41 +++++++++++++++++++++++++++++++++++++++++
> 2 files changed, 43 insertions(+)
> ff3f339e550dc83d300346ec648f778f85900679 0001-windows-respond-to-logoff-and-ctrl-break-messages-as.patch
> From 7ce401dbd16873928bd541d5d567208963b85889 Mon Sep 17 00:00:00 2001
> From: rogerdpack <rogerpack2005 at gmail.com>
> Date: Tue, 30 Jun 2015 12:58:43 -0600
> Subject: [PATCH] windows: respond to logoff and ctrl+break messages as well
>
> Signed-off-by: rogerdpack <rogerpack2005 at gmail.com>
> ---
> configure | 2 ++
> ffmpeg.c | 41 +++++++++++++++++++++++++++++++++++++++++
> 2 files changed, 43 insertions(+)
>
> diff --git a/configure b/configure
> index 89b5668..cc23991 100755
> --- a/configure
> +++ b/configure
> @@ -1787,6 +1787,7 @@ SYSTEM_FUNCS="
> pthread_cancel
> sched_getaffinity
> SetConsoleTextAttribute
> + SetConsoleCtrlHandler
> setmode
> setrlimit
> Sleep
> @@ -4990,6 +4991,7 @@ check_func_headers windows.h GetSystemTimeAsFileTime
> check_func_headers windows.h MapViewOfFile
> check_func_headers windows.h PeekNamedPipe
> check_func_headers windows.h SetConsoleTextAttribute
> +check_func_headers windows.h SetConsoleCtrlHandler
> check_func_headers windows.h Sleep
> check_func_headers windows.h VirtualAlloc
> check_struct windows.h "CONDITION_VARIABLE" Ptr
> diff --git a/ffmpeg.c b/ffmpeg.c
> index aac03bb..b58d891 100644
> --- a/ffmpeg.c
> +++ b/ffmpeg.c
> @@ -79,6 +79,10 @@
> #include <windows.h>
> #include <psapi.h>
> #endif
> +#ifdef HAVE_SETCONSOLECTRLHANDLER
[...]
> +#ifdef HAVE_SETCONSOLECTRLHANDLER
they are defined but to 0 on linux, this needs #if
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
No great genius has ever existed without some touch of madness. -- Aristotle
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20150630/137113e0/attachment.asc>
More information about the ffmpeg-devel
mailing list