diff options
author | Avi Kivity <avi@redhat.com> | 2009-12-07 11:04:32 +0200 |
---|---|---|
committer | Avi Kivity <avi@redhat.com> | 2009-12-07 11:04:32 +0200 |
commit | 149d76049af52aa76f4665b6bc9bdbd5904a8588 (patch) | |
tree | e07c6dfe28f03438dff9bb07240a7534c010f990 /gdbstub.c | |
parent | Merge commit 'e9b2e81889d9877415710484b876ee57a42b0bcb' into upstream-merge (diff) | |
parent | Don't leak file descriptors (diff) | |
download | qemu-kvm-149d76049af52aa76f4665b6bc9bdbd5904a8588.tar.gz qemu-kvm-149d76049af52aa76f4665b6bc9bdbd5904a8588.tar.bz2 qemu-kvm-149d76049af52aa76f4665b6bc9bdbd5904a8588.zip |
Merge commit '40ff6d7e8dceca227e7f8a3e8e0d58b2c66d19b4' into upstream-merge
* commit '40ff6d7e8dceca227e7f8a3e8e0d58b2c66d19b4':
Don't leak file descriptors
qemu-img: There is more than one host device driver
qcow2: Fix some more qemu_malloc fallout
qcow2: Store exact backing format length
virtio-blk: Implement rerror option
ide: Implement rerror option
Conflicts:
posix-aio-compat.c
Extended qemu_set_cloexec() to compatfd.c.
Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'gdbstub.c')
-rw-r--r-- | gdbstub.c | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -2357,6 +2357,9 @@ static void gdb_accept(void) perror("accept"); return; } else if (fd >= 0) { +#ifndef _WIN32 + fcntl(fd, F_SETFD, FD_CLOEXEC); +#endif break; } } @@ -2386,6 +2389,9 @@ static int gdbserver_open(int port) perror("socket"); return -1; } +#ifndef _WIN32 + fcntl(fd, F_SETFD, FD_CLOEXEC); +#endif /* allow fast reuse */ val = 1; |