qemu-trivial
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2] ivshmem-server: Terminate also on SIGINT


From: Laurent Vivier
Subject: Re: [PATCH v2] ivshmem-server: Terminate also on SIGINT
Date: Tue, 12 Nov 2019 10:37:28 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.1.1

Le 08/11/2019 à 16:15, Markus Armbruster a écrit :
> Jan Kiszka <address@hidden> writes:
> 
>> On 03.08.19 15:22, Jan Kiszka wrote:
>>> From: Jan Kiszka <address@hidden>
>>>
>>> Allows to shutdown a foreground session via ctrl-c.
>>>
>>> Signed-off-by: Jan Kiszka <address@hidden>
>>> ---
>>>
>>> Changes in v2:
>>>   - adjust error message
>>>
>>>   contrib/ivshmem-server/main.c | 5 +++--
>>>   1 file changed, 3 insertions(+), 2 deletions(-)
>>>
>>> diff --git a/contrib/ivshmem-server/main.c b/contrib/ivshmem-server/main.c
>>> index 197c79c57e..e4cd35f74c 100644
>>> --- a/contrib/ivshmem-server/main.c
>>> +++ b/contrib/ivshmem-server/main.c
>>> @@ -223,8 +223,9 @@ main(int argc, char *argv[])
>>>       sa_quit.sa_handler = ivshmem_server_quit_cb;
>>>       sa_quit.sa_flags = 0;
>>>       if (sigemptyset(&sa_quit.sa_mask) == -1 ||
>>> -        sigaction(SIGTERM, &sa_quit, 0) == -1) {
>>> -        perror("failed to add SIGTERM handler; sigaction");
>>> +        sigaction(SIGTERM, &sa_quit, 0) == -1 ||
>>> +        sigaction(SIGINT, &sa_quit, 0) == -1) {
>>> +        perror("failed to add signal handler; sigaction");
>>>           goto err;
>>>       }
>>>
>>> --
>>> 2.16.4
>>>
>>>
>>
>> ...and this one for you as well, Markus?
> 
> Cc: qemu-trivial
> 
> 

Applied to my trivial-patches branch.

Thanks,
Laurent



reply via email to

[Prev in Thread] Current Thread [Next in Thread]