diff options
author | Anton Nefedov | 2017-07-25 12:04:41 +0200 |
---|---|---|
committer | Paolo Bonzini | 2017-08-01 17:27:33 +0200 |
commit | 0ec846bface0f9733ca61ba18e3d4b72bfd9f8ca (patch) | |
tree | ba0be0c50679eccff36b1668ec7c8d001ba7e1c6 /include/chardev/char.h | |
parent | char-fd: remove useless chr pointer (diff) | |
download | qemu-0ec846bface0f9733ca61ba18e3d4b72bfd9f8ca.tar.gz qemu-0ec846bface0f9733ca61ba18e3d4b72bfd9f8ca.tar.xz qemu-0ec846bface0f9733ca61ba18e3d4b72bfd9f8ca.zip |
char: don't exit on hmp 'chardev-add help'
qemu_chr_new_from_opts() is used from both vl.c and hmp,
and it is quite confusing to see qemu suddenly exit after receiving a help
option in hmp.
Do exit(0) from vl.c instead.
Signed-off-by: Anton Nefedov <anton.nefedov@virtuozzo.com>
Message-Id: <1500977081-120929-1-git-send-email-anton.nefedov@virtuozzo.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'include/chardev/char.h')
-rw-r--r-- | include/chardev/char.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/include/chardev/char.h b/include/chardev/char.h index 1604ea9143..66dde4637e 100644 --- a/include/chardev/char.h +++ b/include/chardev/char.h @@ -65,7 +65,9 @@ struct Chardev { * * @opts see qemu-config.c for a list of valid options * - * Returns: a new character backend + * Returns: on success: a new character backend + * otherwise: NULL; @errp specifies the error + * or left untouched in case of help option */ Chardev *qemu_chr_new_from_opts(QemuOpts *opts, Error **errp); |