qemu-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-commits] [qemu/qemu] 3d4da9: ui/gtk: fix crash at startup when no


From: GitHub
Subject: [Qemu-commits] [qemu/qemu] 3d4da9: ui/gtk: fix crash at startup when no console is av...
Date: Tue, 10 Jan 2017 10:00:04 -0800

  Branch: refs/heads/master
  Home:   https://github.com/qemu/qemu
  Commit: 3d4da9d6f3b664beb5bee446ad53b69178f46ad4
      
https://github.com/qemu/qemu/commit/3d4da9d6f3b664beb5bee446ad53b69178f46ad4
  Author: Hervé Poussineau <address@hidden>
  Date:   2017-01-10 (Tue, 10 Jan 2017)

  Changed paths:
    M ui/gtk.c

  Log Message:
  -----------
  ui/gtk: fix crash at startup when no console is available

This patch fixes a segfault at QEMU startup, introduced in 
a08156321ab9a7d2fed9ee77dbfeea2a61ffd153.
gd_vc_find_current() return NULL, which is dereferenced without checking it.

While at it, disable the whole 'View' menu if no console exists.

Reproducer: qemu-system-i386 -M none -nodefaults

Signed-off-by: Hervé Poussineau <address@hidden>
Reviewed-by: Stefan Hajnoczi <address@hidden>
Message-id: address@hidden
Signed-off-by: Gerd Hoffmann <address@hidden>


  Commit: a8ffb372a2202c65f42fdb69891ea68a2f274b55
      
https://github.com/qemu/qemu/commit/a8ffb372a2202c65f42fdb69891ea68a2f274b55
  Author: Daniel P. Berrange <address@hidden>
  Date:   2017-01-10 (Tue, 10 Jan 2017)

  Changed paths:
    M include/ui/gtk.h
    M ui/gtk.c

  Log Message:
  -----------
  ui: use evdev keymap when running under wayland

Wayland always uses evdev as its input source, so QEMU
can use the existing evdev keymap data

Signed-off-by: Daniel P. Berrange <address@hidden>
Tested-by: Stefan Hajnoczi <address@hidden>
Message-id: address@hidden
Signed-off-by: Gerd Hoffmann <address@hidden>


  Commit: b3cb21b9b5ece1756a4796e2f2e3d275bf110002
      
https://github.com/qemu/qemu/commit/b3cb21b9b5ece1756a4796e2f2e3d275bf110002
  Author: Samuel Thibault <address@hidden>
  Date:   2017-01-10 (Tue, 10 Jan 2017)

  Changed paths:
    M include/ui/console.h
    M ui/console.c

  Log Message:
  -----------
  console: add API to get underlying gui window ID

This adds two console functions, qemu_console_set_window_id and
qemu_graphic_console_get_window_id, to let graphical backend record the
window id in the QemuConsole structure, and let the baum driver read it.

Signed-off-by: Samuel Thibault <address@hidden>
Message-id: address@hidden
Signed-off-by: Gerd Hoffmann <address@hidden>


  Commit: f29b3431f6294168e5f8fc63edb91c15c6a08e41
      
https://github.com/qemu/qemu/commit/f29b3431f6294168e5f8fc63edb91c15c6a08e41
  Author: Samuel Thibault <address@hidden>
  Date:   2017-01-10 (Tue, 10 Jan 2017)

  Changed paths:
    M backends/baum.c
    M ui/sdl.c

  Log Message:
  -----------
  console: move window ID code from baum to sdl

This moves the SDL bits for window ID from the baum driver to SDL, as
well as fixing the build for non-X11.

Signed-off-by: Samuel Thibault <address@hidden>
Message-id: address@hidden
Signed-off-by: Gerd Hoffmann <address@hidden>


  Commit: d825367172beaa339217c39eca3cf76eeca80056
      
https://github.com/qemu/qemu/commit/d825367172beaa339217c39eca3cf76eeca80056
  Author: Samuel Thibault <address@hidden>
  Date:   2017-01-10 (Tue, 10 Jan 2017)

  Changed paths:
    M ui/sdl2.c

  Log Message:
  -----------
  sdl2: set window ID

This uses the console API to record the window ID of the SDL2 windows.

Signed-off-by: Samuel Thibault <address@hidden>
Message-id: address@hidden
Signed-off-by: Gerd Hoffmann <address@hidden>


  Commit: 6250dff39a358a5f61cbaf085bf8be739a6c73f3
      
https://github.com/qemu/qemu/commit/6250dff39a358a5f61cbaf085bf8be739a6c73f3
  Author: Frediano Ziglio <address@hidden>
  Date:   2017-01-10 (Tue, 10 Jan 2017)

  Changed paths:
    M ui/egl-helpers.c

  Log Message:
  -----------
  egl-helpers: Change file licensing to LGPLv2

The relicense permits sharing the code with Spice which
is LGPL.

All people listed below have agreed to the
relicense:
- Arei Gonglei;
- Cole Robinson;
- Gerd Hoffmann;
- Peter Maydell.

Signed-off-by: Frediano Ziglio <address@hidden>
Acked-by: Cole Robinson <address@hidden>
Acked-by: Gonglei <address@hidden>
Acked-by: Peter Maydell <address@hidden>
Message-id: address@hidden
Signed-off-by: Gerd Hoffmann <address@hidden>


  Commit: c952b71582e2e4be286087ad34de5e3ec1b8d974
      
https://github.com/qemu/qemu/commit/c952b71582e2e4be286087ad34de5e3ec1b8d974
  Author: Marc-André Lureau <address@hidden>
  Date:   2017-01-10 (Tue, 10 Jan 2017)

  Changed paths:
    M ui/gtk.c

  Log Message:
  -----------
  gtk: avoid oob array access

When too many consoles are created, vcs[] may be write out-of-bounds.

Signed-off-by: Marc-André Lureau <address@hidden>
Message-id: address@hidden
Signed-off-by: Gerd Hoffmann <address@hidden>


  Commit: 97efe4f961dcf5a0126baa75e8a6bff66d33186f
      
https://github.com/qemu/qemu/commit/97efe4f961dcf5a0126baa75e8a6bff66d33186f
  Author: Thomas Huth <address@hidden>
  Date:   2017-01-10 (Tue, 10 Jan 2017)

  Changed paths:
    M ui/vnc.c

  Log Message:
  -----------
  ui/vnc: Fix problem with sending too many bytes as server name

If the buffer is not big enough, snprintf() does not return the number
of bytes that have been written to the buffer, but the number of bytes
that would be needed for writing the whole string. By using this value
for the following vnc_write() calls, we send some junk at the end of
the name in case the qemu_name is longer than 1017 bytes, which could
confuse the VNC clients. Fix this by adding an additional size check
here.

Buglink: https://bugs.launchpad.net/qemu/+bug/1637447
Signed-off-by: Thomas Huth <address@hidden>
Reviewed-by: Eric Blake <address@hidden>
Message-id: address@hidden
Signed-off-by: Gerd Hoffmann <address@hidden>


  Commit: f27ff81070b0cc4f5906361964563cc680febe2d
      
https://github.com/qemu/qemu/commit/f27ff81070b0cc4f5906361964563cc680febe2d
  Author: Stefan Weil <address@hidden>
  Date:   2017-01-10 (Tue, 10 Jan 2017)

  Changed paths:
    M include/ui/console.h
    M ui/curses.c

  Log Message:
  -----------
  curses: Fix compiler warnings (Mingw-w64 redefinition of macro KEY_EVENT)

For builds with Mingw-w64 as it is included in Cygwin, there are two
header files which define KEY_EVENT with different values.

This results in lots of compiler warnings like this one:

  CC      vl.o
In file included from /qemu/include/ui/console.h:340:0,
           from /qemu/vl.c:76:
/usr/i686-w64-mingw32/sys-root/mingw/include/curses.h:1522:0: warning: 
"KEY_EVENT" redefined
 #define KEY_EVENT 0633  /* We were interrupted by an event */

In file included from /usr/share/mingw-w64/include/windows.h:74:0,
           from /usr/share/mingw-w64/include/winsock2.h:23,
           from /qemu/include/sysemu/os-win32.h:29,
           from /qemu/include/qemu/osdep.h:100,
           from /qemu/vl.c:24:
/usr/share/mingw-w64/include/wincon.h:101:0: note: this is the location of the 
previous definition
 #define KEY_EVENT 0x1

QEMU only uses the KEY_EVENT macro from wincon.h.
Therefore we can undefine the macro coming from curses.h.

The explicit include statement for curses.h in ui/curses.c is not needed
and was removed.

Those two modifications fix the redefinition warnings.

Signed-off-by: Stefan Weil <address@hidden>
Acked-by: Samuel Thibault <address@hidden>
Message-id: address@hidden
Signed-off-by: Gerd Hoffmann <address@hidden>


  Commit: e934644126f214a99bb3b3201f73fe7f0c579ef7
      
https://github.com/qemu/qemu/commit/e934644126f214a99bb3b3201f73fe7f0c579ef7
  Author: OGAWA Hirofumi <address@hidden>
  Date:   2017-01-10 (Tue, 10 Jan 2017)

  Changed paths:
    M hw/input/ps2.c
    M qapi-schema.json
    M ui/input-keymap.c

  Log Message:
  -----------
  ps2: Fix lost scancodes by recent changes

With "ps2: use QEMU qcodes instead of scancodes", key handling was
changed to qcode base. But all scancodes are not converted to new one.

This adds some missing qcodes/scancodes what I found in using.

[set1 and set3 are from <address@hidden>]
Signed-off-by: OGAWA Hirofumi <address@hidden>
Reviewed-by: Hervé Poussineau <address@hidden>
Signed-off-by: Gerd Hoffmann <address@hidden>


  Commit: b44486dfb9447c88e4b216e730adcc780190852c
      
https://github.com/qemu/qemu/commit/b44486dfb9447c88e4b216e730adcc780190852c
  Author: Peter Maydell <address@hidden>
  Date:   2017-01-10 (Tue, 10 Jan 2017)

  Changed paths:
    M backends/baum.c
    M hw/input/ps2.c
    M include/ui/console.h
    M include/ui/gtk.h
    M qapi-schema.json
    M ui/console.c
    M ui/curses.c
    M ui/egl-helpers.c
    M ui/gtk.c
    M ui/input-keymap.c
    M ui/sdl.c
    M ui/sdl2.c
    M ui/vnc.c

  Log Message:
  -----------
  Merge remote-tracking branch 'remotes/kraxel/tags/pull-ui-20170110-1' into 
staging

gtk,vnc: misc bugfixes.
kbd: add jp keys, fix ps2 regressions.
sdl: export window id for baum, remove sdl hooks from baum.
egl: egl-helpers.c license change.

# gpg: Signature made Tue 10 Jan 2017 07:16:05 GMT
# gpg:                using RSA key 0x4CB6D8EED3E87138
# gpg: Good signature from "Gerd Hoffmann (work) <address@hidden>"
# gpg:                 aka "Gerd Hoffmann <address@hidden>"
# gpg:                 aka "Gerd Hoffmann (private) <address@hidden>"
# Primary key fingerprint: A032 8CFF B93A 17A7 9901  FE7D 4CB6 D8EE D3E8 7138

* remotes/kraxel/tags/pull-ui-20170110-1:
  ps2: Fix lost scancodes by recent changes
  curses: Fix compiler warnings (Mingw-w64 redefinition of macro KEY_EVENT)
  ui/vnc: Fix problem with sending too many bytes as server name
  gtk: avoid oob array access
  egl-helpers: Change file licensing to LGPLv2
  sdl2: set window ID
  console: move window ID code from baum to sdl
  console: add API to get underlying gui window ID
  ui: use evdev keymap when running under wayland
  ui/gtk: fix crash at startup when no console is available

Signed-off-by: Peter Maydell <address@hidden>


Compare: https://github.com/qemu/qemu/compare/41a0e54756a9...b44486dfb944

reply via email to

[Prev in Thread] Current Thread [Next in Thread]