1. 10 Jul, 2020 3 commits
  2. 01 Jul, 2020 1 commit
  3. 26 Jun, 2020 10 commits
  4. 09 Jun, 2020 1 commit
  5. 05 Jun, 2020 1 commit
  6. 22 May, 2020 2 commits
  7. 19 May, 2020 2 commits
  8. 07 May, 2020 1 commit
  9. 01 May, 2020 1 commit
  10. 09 Apr, 2020 1 commit
  11. 03 Apr, 2020 3 commits
  12. 19 Feb, 2020 1 commit
  13. 07 Feb, 2020 1 commit
  14. 17 Jan, 2020 1 commit
    • Francesco Giudici's avatar
      remote-viewer: add handler for SIGINT signal · a724dff8
      Francesco Giudici authored
      When remote-viewer is started from terminal, CTRL-C sends a SIGINT
      signal to the program causing immediate termination. On linux clients
      usb redirected devices are left without any kernel driver attached,
      causing them to appear as no more available to the host.
      Add a SIGINT handler to allow a clean exit, in particular to allow
      the kernel to attach back the host driver.
      The issue is present on linux only.
      
      To perform usb device redirection, virt-viewer leverages spice-gtk
      library, which in turn relies on usbredir library, which uses libusb.
      In order to take control of the usb device the auto-loaded kernel
      driver must be detached. This is achieved (in the very end) with
      libusb_detach_kernel_driver(). Then the device interfaces can be claimed
      with libusb_claim_interface() and get in control to the application.
      During normal application termination, the usb channel is teared down,
      performing a reset of the usb device and giving back the control of the
      device to the kernel (libusb_attach_kernel_driver()).
      If the application quits without doing this, the device interfaces will
      end up with no driver attached, making them not usable in the host
      system.
      
      Note that enabling libusb_set_auto_detach_kernel_driver() does not solve
      the issue, as this is just a convenient API from libusb: libusb will
      take care of detaching/attaching the driver to the interfaces of the usb
      device each time a call to libusb_release_interface() and
      libusb_claim_interface() is performed. An unexpected quit of the
      application will skip the libusb_release_interface() call too, leaving
      the interfaces without any driver attached.
      
      Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1713311Reviewed-by: Daniel Berrange's avatarDaniel P. Berrangé <[email protected]>
      Signed-off-by: default avatarFrancesco Giudici <[email protected]>
      a724dff8
  15. 16 Dec, 2019 1 commit
  16. 11 Oct, 2019 1 commit
  17. 04 Oct, 2019 1 commit
    • Victor Toso's avatar
      remote-viewer: fix free on dangling pointer · a13173ae
      Victor Toso authored
      On remote_viewer_session_connected() we are passing a dup of URI of
      connection and freeing it afterwards. Problem is, we don't disconnect
      from listening "session-connected" and on an eventual second emission
      of this signal, remote-viewer crashes as seen in the backtrace below.
      
      This can happen over switch-host migration message from
      SpiceMainChannel.
      
      A fix trying to use VirtViewerApp URI avoid the crash but introduces
      regression while running remote-viewer with ovirt so, keeping the
      changes to a minimum to avoid it, just use g_intern_string() for now.
      
      Found it while improving migrate.py from spice/tests (server):
       | Invalid free() / delete / delete[] / realloc()
       |    at 0x4839A0C: free (vg_replace_malloc.c:540)
       |    by 0x56EBD8C: g_free (in /usr/lib64/libglib-2.0.so.0.6000.6)
       |    by 0x11DED0: remote_viewer_session_connected (remote-viewer.c:658)
       |    by 0x564D741: g_closure_invoke (in /usr/lib64/libgobject-2.0.so.0.6000.6)
       |    by 0x56614F3: ??? (in /usr/lib64/libgobject-2.0.so.0.6000.6)
       |    by 0x566A34D: g_signal_emit_valist (in /usr/lib64/libgobject-2.0.so.0.6000.6)
       |    by 0x566AF68: g_signal_emit_by_name (in /usr/lib64/libgobject-2.0.so.0.6000.6)
       |    by 0x135E5D: virt_viewer_session_spice_main_channel_event (virt-viewer-session-spice.c:699)
       |    by 0x564D741: g_closure_invoke (in /usr/lib64/libgobject-2.0.so.0.6000.6)
       |    by 0x56614F3: ??? (in /usr/lib64/libgobject-2.0.so.0.6000.6)
       |    by 0x566A34D: g_signal_emit_valist (in /usr/lib64/libgobject-2.0.so.0.6000.6)
       |    by 0x53149E3: emit_main_context (gio-coroutine.c:198)
       |  Address 0x18f1ecc0 is 0 bytes inside a block of size 23 free'd
       |    at 0x4839A0C: free (vg_replace_malloc.c:540)
       |    by 0x56EBD8C: g_free (in /usr/lib64/libglib-2.0.so.0.6000.6)
       |    by 0x11DED0: remote_viewer_session_connected (remote-viewer.c:658)
       |    by 0x564D741: g_closure_invoke (in /usr/lib64/libgobject-2.0.so.0.6000.6)
       |    by 0x56614F3: ??? (in /usr/lib64/libgobject-2.0.so.0.6000.6)
       |    by 0x566A34D: g_signal_emit_valist (in /usr/lib64/libgobject-2.0.so.0.6000.6)
       |    by 0x566AF68: g_signal_emit_by_name (in /usr/lib64/libgobject-2.0.so.0.6000.6)
       |    by 0x135E5D: virt_viewer_session_spice_main_channel_event (virt-viewer-session-spice.c:699)
       |    by 0x564D741: g_closure_invoke (in /usr/lib64/libgobject-2.0.so.0.6000.6)
       |    by 0x56614F3: ??? (in /usr/lib64/libgobject-2.0.so.0.6000.6)
       |    by 0x566A34D: g_signal_emit_valist (in /usr/lib64/libgobject-2.0.so.0.6000.6)
       |    by 0x53149E3: emit_main_context (gio-coroutine.c:198)
       |  Block was alloc'd at
       |    at 0x483880B: malloc (vg_replace_malloc.c:309)
       |    by 0x56EBC98: g_malloc (in /usr/lib64/libglib-2.0.so.0.6000.6)
       |    by 0x5705C43: g_strdup (in /usr/lib64/libglib-2.0.so.0.6000.6)
       |    by 0x11EB80: remote_viewer_initial_connect (remote-viewer.c:696)
       |    by 0x11EB80: remote_viewer_start (remote-viewer.c:790)
       |    by 0x1250D3: virt_viewer_app_start (virt-viewer-app.c:1727)
       |    by 0x127108: virt_viewer_app_on_application_startup (virt-viewer-app.c:1870)
       |    by 0x564D741: g_closure_invoke (in /usr/lib64/libgobject-2.0.so.0.6000.6)
       |    by 0x5661638: ??? (in /usr/lib64/libgobject-2.0.so.0.6000.6)
       |    by 0x566A34D: g_signal_emit_valist (in /usr/lib64/libgobject-2.0.so.0.6000.6)
       |    by 0x566A972: g_signal_emit (in /usr/lib64/libgobject-2.0.so.0.6000.6)
       |    by 0x553ECA1: g_application_register (in /usr/lib64/libgio-2.0.so.0.6000.6)
       |    by 0x553F41D: g_application_run (in /usr/lib64/libgio-2.0.so.0.6000.6)
      Signed-off-by: Victor Toso's avatarVictor Toso <[email protected]>
      Acked-by: default avatarEduardo Lima (Etrunko) <[email protected]>
      a13173ae
  18. 30 Aug, 2019 1 commit
    • Eduardo Lima (Etrunko)'s avatar
      ovirt-foreign-menu: Plug memory leak · c1998594
      Eduardo Lima (Etrunko) authored
      Error caught by valgrind, the OvirtCollection object created in function
      ovirt_foreign_menu_fetch_vm_async() was never freed.
      
      433 (40 direct, 393 indirect) bytes in 1 blocks are definitely lost in loss record 16,708 of 17,677
         at 0x5868FDF: g_type_create_instance (in /usr/lib64/libgobject-2.0.so.0.6000.6)
         by 0x584B42C: ??? (in /usr/lib64/libgobject-2.0.so.0.6000.6)
         by 0x584D347: g_object_new_valist (in /usr/lib64/libgobject-2.0.so.0.6000.6)
         by 0x584D69C: g_object_new (in /usr/lib64/libgobject-2.0.so.0.6000.6)
         by 0x558E823: ovirt_collection_new (ovirt-collection.c:304)
         by 0x558E98C: ovirt_sub_collection_new_from_resource_search (ovirt-collection.c:375)
         by 0x42D510: ovirt_foreign_menu_fetch_vm_async (ovirt-foreign-menu.c:994)
         by 0x42D510: ovirt_foreign_menu_next_async_step (ovirt-foreign-menu.c:316)
         by 0x42D70D: api_fetched_cb (ovirt-foreign-menu.c:1025)
         by 0x570BC19: ??? (in /usr/lib64/libgio-2.0.so.0.6000.6)
         by 0x570C7EC: ??? (in /usr/lib64/libgio-2.0.so.0.6000.6)
         by 0x559005D: call_async_cb (ovirt-proxy.c:279)
         by 0x55B5A07: ??? (in /usr/lib64/librest-0.7.so.0.0.0)
      Signed-off-by: default avatarEduardo Lima (Etrunko) <[email protected]>
      Acked-by: Victor Toso's avatarVictor Toso <[email protected]>
      c1998594
  19. 26 Aug, 2019 1 commit
  20. 21 Aug, 2019 1 commit
  21. 15 Aug, 2019 1 commit
  22. 12 Aug, 2019 1 commit
  23. 08 Aug, 2019 1 commit
    • Kevin Pouget's avatar
      virt-viewer-file-transfer-dialog: improve error message · a2a372ac
      Kevin Pouget authored
      This patch improves the error shown to the user when a file transfer
      fails.
      
      The previous behavior was to create a simple message dialog box, with
      the error description and the full list of the files that failed to be
      transferred. When the list of files was long, the dialog box would
      grow bigger than the screen.
      
      Now, the file list is inserted inside a scrollable widget, whose
      height is limited to 170px.
      
      NB: these two calls would be more adapted, but they require GTK >=
      3.22:
      
      > gtk_scrolled_window_set_max_content_height(GTK_SCROLLED_WINDOW(scrolled_window), 170);
      > gtk_scrolled_window_set_propagate_natural_height(GTK_SCROLLED_WINDOW(scrolled_window), TRUE);
      
      Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1496356Signed-off-by: Kevin Pouget's avatarKevin Pouget <[email protected]>
      Acked-by: Victor Toso's avatarVictor Toso <[email protected]>
      a2a372ac
  24. 19 Jun, 2019 1 commit
  25. 31 May, 2019 1 commit