qemu with hax to log dma reads & writes jcs.org/2018/11/12/vfio

Merge remote-tracking branch 'remotes/kraxel/tags/pull-vnc-20160803-1' into staging

vnc: fixes for "-vnc none".

# gpg: Signature made Wed 03 Aug 2016 16:33:07 BST
# gpg: using RSA key 0x4CB6D8EED3E87138
# gpg: Good signature from "Gerd Hoffmann (work) <kraxel@redhat.com>"
# gpg: aka "Gerd Hoffmann <gerd@kraxel.org>"
# gpg: aka "Gerd Hoffmann (private) <kraxel@gmail.com>"
# Primary key fingerprint: A032 8CFF B93A 17A7 9901 FE7D 4CB6 D8EE D3E8 7138

* remotes/kraxel/tags/pull-vnc-20160803-1:
vnc: ensure connection sharing/limits is always configured
vnc: fix crash when vnc_server_info_get has an error
vnc: don't crash getting server info if lsock is NULL

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>

+9 -1
+9 -1
ui/vnc.c
··· 143 143 { 144 144 SocketAddress *addr = NULL; 145 145 146 + if (!ioc) { 147 + error_setg(errp, "No listener socket available"); 148 + return; 149 + } 150 + 146 151 addr = qio_channel_socket_get_local_address(ioc, errp); 147 152 if (!addr) { 148 153 return; ··· 219 224 VncServerInfo *info; 220 225 Error *err = NULL; 221 226 222 - info = g_malloc(sizeof(*info)); 227 + info = g_malloc0(sizeof(*info)); 223 228 vnc_init_basic_info_from_server_addr(vd->lsock, 224 229 qapi_VncServerInfo_base(info), &err); 225 230 info->has_auth = true; ··· 3144 3149 3145 3150 if (!vs->kbd_layout) 3146 3151 exit(1); 3152 + 3153 + vs->share_policy = VNC_SHARE_POLICY_ALLOW_EXCLUSIVE; 3154 + vs->connections_limit = 32; 3147 3155 3148 3156 qemu_mutex_init(&vs->mutex); 3149 3157 vnc_start_worker_thread();