diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2021-09-05 15:48:42 +0100 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2021-09-05 15:48:42 +0100 |
commit | 88afdc92b644120e0182c8567e1b1d236e471b12 (patch) | |
tree | 13feb13c6ffec9a2785440033c245389a12531fa /tests | |
parent | 31ebff513fad11f315377f6b07447169be8d9f86 (diff) | |
parent | 499c8b4de96eecc554a03e452226f79f169a233b (diff) |
Merge remote-tracking branch 'remotes/mst/tags/for_upstream' into staging
pc,pci,virtio: fixes, cleanups
Fixes, cleanups all over the place.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
# gpg: Signature made Sat 04 Sep 2021 22:34:10 BST
# gpg: using RSA key 5D09FD0871C8F85B94CA8A0D281F0DB8D28D5469
# gpg: issuer "mst@redhat.com"
# gpg: Good signature from "Michael S. Tsirkin <mst@kernel.org>" [full]
# gpg: aka "Michael S. Tsirkin <mst@redhat.com>" [full]
# Primary key fingerprint: 0270 606B 6F3C DF3D 0B17 0970 C350 3912 AFBE 8E67
# Subkey fingerprint: 5D09 FD08 71C8 F85B 94CA 8A0D 281F 0DB8 D28D 5469
* remotes/mst/tags/for_upstream: (35 commits)
vhost-vdpa: remove the unncessary queue_index assignment
vhost-vdpa: fix the wrong assertion in vhost_vdpa_init()
vhost-vdpa: tweak the error label in vhost_vdpa_add()
vhost-vdpa: fix leaking of vhost_net in vhost_vdpa_add()
vhost-vdpa: don't cleanup twice in vhost_vdpa_add()
vhost-vdpa: remove the unnecessary check in vhost_vdpa_add()
vhost_net: do not assume nvqs is always 2
vhost: use unsigned int for nvqs
vhost_net: remove the meaningless assignment in vhost_net_start_one()
vhost-vdpa: correctly return err in vhost_vdpa_set_backend_cap()
vhost-vdpa: remove unused variable "acked_features"
tests/vhost-user-bridge.c: Fix typo in help message
tests/vhost-user-bridge.c: Sanity check socket path length
hw/virtio: Add flatview update in vhost_user_cleanup()
hw/virtio: Remove NULL check in virtio_free_region_cache()
hw/virtio: Document virtio_queue_packed_empty_rcu is called within RCU
MAINTAINERS: Added myself as a reviewer for acpi/smbios subsystem
hw/acpi: use existing references to pci device struct within functions
hw/pci: remove all references to find_i440fx function
hw/i386/acpi-build: Get NUMA information from struct NumaState
...
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/vhost-user-bridge.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/tests/vhost-user-bridge.c b/tests/vhost-user-bridge.c index 24815920b2..35088dd67f 100644 --- a/tests/vhost-user-bridge.c +++ b/tests/vhost-user-bridge.c @@ -540,6 +540,11 @@ vubr_new(const char *path, bool client) CallbackFunc cb; size_t len; + if (strlen(path) >= sizeof(un.sun_path)) { + fprintf(stderr, "unix domain socket path '%s' is too long\n", path); + exit(1); + } + /* Get a UNIX socket. */ dev->sock = socket(AF_UNIX, SOCK_STREAM, 0); if (dev->sock == -1) { @@ -826,7 +831,7 @@ main(int argc, char *argv[]) out: fprintf(stderr, "Usage: %s ", argv[0]); fprintf(stderr, "[-c] [-H] [-u ud_socket_path] [-l lhost:lport] [-r rhost:rport]\n"); - fprintf(stderr, "\t-u path to unix doman socket. default: %s\n", + fprintf(stderr, "\t-u path to unix domain socket. default: %s\n", DEFAULT_UD_SOCKET); fprintf(stderr, "\t-l local host and port. default: %s:%s\n", DEFAULT_LHOST, DEFAULT_LPORT); |