diff options
| author | Peter Maydell <peter.maydell@linaro.org> | 2015-11-06 12:50:24 +0000 |
|---|---|---|
| committer | Peter Maydell <peter.maydell@linaro.org> | 2015-11-06 12:50:24 +0000 |
| commit | 4b59f39bc9a03afcc74b2fa28da7c3189fca507c (patch) | |
| tree | 8c5c06154146e8cda32837ae6d3ad7a3e74009a1 /ui/vnc.c | |
| parent | 9319738080faeb09876ce2017fcaea4937c475ee (diff) | |
| parent | bd54a9f9435c85de190a82019faef16c5ecf8e46 (diff) | |
| download | focaccia-qemu-4b59f39bc9a03afcc74b2fa28da7c3189fca507c.tar.gz focaccia-qemu-4b59f39bc9a03afcc74b2fa28da7c3189fca507c.zip | |
Merge remote-tracking branch 'remotes/mjt/tags/pull-trivial-patches-2015-11-06' into staging
trivial patches for 2015-11-06 # gpg: Signature made Fri 06 Nov 2015 12:42:43 GMT using RSA key ID A4C3D7DB # gpg: Good signature from "Michael Tokarev <mjt@tls.msk.ru>" # gpg: aka "Michael Tokarev <mjt@corpit.ru>" # gpg: aka "Michael Tokarev <mjt@debian.org>" * remotes/mjt/tags/pull-trivial-patches-2015-11-06: (24 commits) tap-bsd: use user-specified tap device if it already exists qemu-sockets: do not test path with access() before unlinking taget-ppc: Fix read access to IBAT registers higher than IBAT3 exec: avoid unnecessary cacheline bounce on ram_list.mru_block target-alpha: fix uninitialized variable ivshmem-server: fix possible OVERRUN pci-assign: do not test path with access() before opening qom/object: fix 2 comment typos configure: remove help string for 'vnc-tls' option usb: Use g_new() & friends where that makes obvious sense qxl: Use g_new() & friends where that makes obvious sense ui: Use g_new() & friends where that makes obvious sense bt: fix use of uninitialized variable seqlen hw/dma/pxa2xx: Remove superfluous memset linux-user/syscall: Replace g_malloc0 + memcpy with g_memdup tests/i44fx-test: No need for zeroing memory before memset hw/input/tsc210x: Remove superfluous memset xen: fix invalid assertion tests: ignore test-qga fix bad indentation in pcie_cap_slot_write_config() ... Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'ui/vnc.c')
| -rw-r--r-- | ui/vnc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ui/vnc.c b/ui/vnc.c index a47f2b382c..f20c08db4a 100644 --- a/ui/vnc.c +++ b/ui/vnc.c @@ -2982,7 +2982,7 @@ static void vnc_refresh(DisplayChangeListener *dcl) static void vnc_connect(VncDisplay *vd, int csock, bool skipauth, bool websocket) { - VncState *vs = g_malloc0(sizeof(VncState)); + VncState *vs = g_new0(VncState, 1); int i; vs->csock = csock; @@ -3005,7 +3005,7 @@ static void vnc_connect(VncDisplay *vd, int csock, vs->lossy_rect = g_malloc0(VNC_STAT_ROWS * sizeof (*vs->lossy_rect)); for (i = 0; i < VNC_STAT_ROWS; ++i) { - vs->lossy_rect[i] = g_malloc0(VNC_STAT_COLS * sizeof (uint8_t)); + vs->lossy_rect[i] = g_new0(uint8_t, VNC_STAT_COLS); } VNC_DEBUG("New client on socket %d\n", csock); |