IF YOU WOULD LIKE TO GET AN ACCOUNT, please write an
email to Administrator. User accounts are meant only to access repo
and report issues and/or generate pull requests.
This is a purpose-specific Git hosting for
BaseALT
projects. Thank you for your understanding!
Только зарегистрированные пользователи имеют доступ к сервису!
Для получения аккаунта, обратитесь к администратору.
All the g_printerr does is printing the message of the GError with a
newline at the end. Hence, use a simple format string without the need
to translate it.
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
Currently there is a strings with four placeholders that represents
optional bits: the "press to release", a whitespace (!), the subtitle,
and the application title. This is suboptimal, because it hides the way
the title is composed, and makes it hard to properly translate.
Instead of this string puzzle, create separate strings for each case
(there are only four of them, and one is only the application title).
Each of the string has all the static text availale, with a proper
comment explaining the layout.
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
Give them a context to explain what is the "unknown thing", so it is
possible to provide proper translations.
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
Turn the menu labels into GTK accelerator strings, so we can parse them
to convert them into a proper user representation.
There is a small behaviour change: the menu items do not have mnemonics
anymore by default.
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
Switch the homepage URL to https, and synchronize the label with the
URL. Also, do not make the label translatable, as it is pointless (it is
only a URL).
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
Use the standard gpl-2-0 license type of GtkAboutDialog, instead of the
custom license text: this way, the dialog will show a translated text
with the license type, and a link to the full license text.
As side change due to the editing of this file in glade 3.36: set the
logo icon name to "virt-viewer", even if at runtime a logo/image will be
loaded. glade needs a logo set, either as icon name or as pixmap.
Signed-off-by: Pino Toscano <ptoscano@redhat.com>
Instead of showing just a generic error with a list of files group
files by error and show them.
This solves https://bugzilla.redhat.com/show_bug.cgi?id=1753563
Signed-off-by: Frediano Ziglio <freddy77@gmail.com>
The default key accelerator to release mouse if left control and
left alt but the current description is "Ctrl+Alt", change to
"Ctrl_L+Alt_L" to avoid misunderstanding.
This solves https://bugzilla.redhat.com/show_bug.cgi?id=1548371
Signed-off-by: Frediano Ziglio <freddy77@gmail.com>
Weblate gets confused if the same email address is mentioned multiple
times in the translation headers. Dedupe authors so that each author
is mentioned only once, with a range of years listed.
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Weblate works a slightly different way than Zanata. Instead of manually
pushing a pot file and fetching po files, Weblate is going to work
automatically with GitLab Merge requests. The main pot file must be
committed to git, and then Weblate fully manages the .po files, using
merge requests to send updates back.
With this new system we don't have a separate .mini.po file. The main
.po file is partially minimized by removing locations but does not
have non-translated msgids removed. This is not a big downside if we
consider that over time most translations should trend towards 100%
translated, and we have purged all 100% non-translated languages.
The main .pot file is generated with alphabetic sort ordering instead
of the default source file location ordering, as this makes the diffs
stable across renames/code movement, which is something we used in the
old .mini.po files.
The only rules needed in the makefile are to refresh the .pot file
and to generate the .gmo files at install time. We must never touch
the .po files locally, not even to rebase them when the .pot is
updated, as that will create merge conflicts with Weblate. Weblate
will take care of all rebases of the .po files in its own fork of
the git repo, and open merge requests to send changes back when
needed.
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
There is no benefit to keeping .po files in git for languages which
have zero translated strings. make should also be honouring the list
in the LINGUAS file, not repeating it.
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Previously meson searched $PATH for libgcrypt-config, but it no longer
does this for cross-builds.
The dockerfile changes can be dropped when the following hits rawhide
container images:
https://bugzilla.redhat.com/show_bug.cgi?id=1856446
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Do not leak memory in case of task cancelled.
Quote "msg" in case it contains some no-xml character that could
came from translated strings.
Signed-off-by: Frediano Ziglio <freddy77@gmail.com>
Make "modifiers" static, potentially avoids a copy to stack.
Use G_N_ELEMENTS also to allocate keys, as in the next loop
allowing to easily change "modifiers" size.
Signed-off-by: Frediano Ziglio <freddy77@gmail.com>
Instead of a fail simply reply that there are no ISO files.
Message text was suggested by Radek Duda who reported the issue.
Signed-off-by: Frediano Ziglio <freddy77@gmail.com>
Currently on every distro we build against the latest git libvirt
and related deps. We need to test multiple axis:
- A variety of libvirt versions
- A variety of distro versions
So this changes most jobs to build against the distro provided
libvirt and related deps. The CentOS 8 job is kept building
against latest git master libvirt and deps.
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
We get this indirectly via govirt, but since we directly use its APIs,
we should list it as an explicit dep too.
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Now that we support both ISO and DATA storage domain types, we need to
make sure that the files are listed correctly. In this case we give the
domains of ISO type the precedence over DATA ones.
This change extends previous commit bbda3aa which made it possible for
storage domains of type DATA to be considered valid.
Signed-off-by: Eduardo Lima (Etrunko) <etrunko@redhat.com>
Unlike the StorageDomain objects of ISO type, the DATA ones require a
specific API recently added to libgovirt to support them. This commit
makes use of those new functions under #ifdef guards and adds proper a
check to configure.ac.
Related: https://bugzilla.redhat.com/show_bug.cgi?id=1847223
Signed-off-by: Eduardo Lima (Etrunko) <etrunko@redhat.com>
This prevents the silent overwriting of the file, and still makes sure the user knows why we don't proceed.
Fix BZ#1752514
Signed-off-by: Julien Ropé <jrope@redhat.com>
Instead of building our own DCO check image, just reuse the common image
provided by the libvirt-ci project.
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
The current code is using a single event handler for leave/enter and
looking at the mouse coordinates to decide whether it entered or left
the widget. This logic is completely broken when the window is
mimimized, because the mouse coordinates of the leave event are still
within the window boundary.
Switch to just have a separate handler for enter/leave events and stop
looking at mouse coordinates entirely.
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
The project primary git repo has moved from pagure.io to
gitlab.com/virt-viewer/virt-viewer. We want users to submit
code contributions, bug reports and support questions to the
gitlab project, not the mailing list, nor bugzilla, nor the
virt-manager.org site.
We're still using virt-manager.org for hosting downloads of
source and pagure.io for MSIs, but we'll aim to change that
too.
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
The error code returned by virt_viewer_session_open_fd() and
virt_viewer_session_channel_open_fd() were not checked. The file
descriptor passed to them could then be left opened even if the function
failed, causing a leak of resources.
This was reported by a Coverity scan, logged under
https://bugzilla.redhat.com/show_bug.cgi?id=1655792
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Signed-off-by: Julien Ropé <jrope@redhat.com>
When doing a screenshot, if the user provides a filename without a file
extension, an error occurs because the image format could not be determined.
This patch adds a .png extension to such filenames, so that there is a default
file format for screenshots.
Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1752514
Reviewed-by: Victor Toso <victortoso@redhat.com>
Signed-off-by: Julien Ropé <jrope@redhat.com>
When the application is stopped, if the windows are in fullscreen, their
position on the client will be remembered.
This change uses the existing option 'monitor-mapping' in the settings
file to save the position and reuse it on next launch.
This implements part of the requirement from
https://bugzilla.redhat.com/show_bug.cgi?id=1179070
NOTE: this feature is effective only with GTK >= 3.22
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Signed-off-by: Julien Ropé <jrope@redhat.com>
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=1713311
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Signed-off-by: Francesco Giudici <fgiudici@redhat.com>
Since oVirt engine version 4.3.2.1, the API returns certificate data for
display connection in the VM XML, so users do not need to specify it
from the command line anymore. The certificate obtained from the XML
gets precedence over the one from the command line, which is still kept
to keep compatibility of older versions of oVirt.
Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1402909
Signed-off-by: Eduardo Lima (Etrunko) <etrunko@redhat.com>
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 <victortoso@redhat.com>
Acked-by: Eduardo Lima (Etrunko) <etrunko@redhat.com>
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: Eduardo Lima (Etrunko) <etrunko@redhat.com>
Acked-by: Victor Toso <victortoso@redhat.com>