mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-02 07:13:54 -06:00
ignore SIGPIPE in qemu-img and qemu-io
This prevents the tools from being stopped when they write data to a closed connection in the other side. Signed-off-by: MORITA Kazutaka <morita.kazutaka@lab.ntt.co.jp> Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
This commit is contained in:
parent
fc11eb26ce
commit
526eda14a6
2 changed files with 8 additions and 0 deletions
|
@ -335,6 +335,10 @@ int main(int argc, char **argv)
|
|||
int opt_index = 0;
|
||||
int flags = BDRV_O_UNMAP;
|
||||
|
||||
#ifdef CONFIG_POSIX
|
||||
signal(SIGPIPE, SIG_IGN);
|
||||
#endif
|
||||
|
||||
progname = basename(argv[0]);
|
||||
|
||||
while ((c = getopt_long(argc, argv, sopt, lopt, &opt_index)) != -1) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue