Richard W.M. Jones
880ccfe824
lib/qemu.c: Add debugging to generic_qmp_test()
...
This function fails sometimes on s390x, but it's hard to tell what is
going on because of insufficient debugging.
(cherry picked from commit bbbc982bf5 )
2026-01-19 18:55:19 +00:00
Richard W.M. Jones
c4eb878d52
lib/qemu.c: Turn debug messages which are really errors into error()
...
Commit 669eda1e24 ("lib/launch-direct.c: Simplify test for KVM, remove
qemu caching") made it so that failure of generic_qmp_test() will
cause launch to fail. However we still used debug messages to print
the error, so unless you have debugging enabled you wouldn't see any
error message if this function fails.
Updates: commit 669eda1e24
(cherry picked from commit 0fe8c0492c )
2026-01-19 18:55:16 +00:00
Richard W.M. Jones
d618d8eb0c
Version 1.58.0.
v1.58.0
2026-01-05 16:19:15 +00:00
Richard W.M. Jones
522c564298
docs/guestfs-release-notes-1.58.pod: Update for 1.58 release
2026-01-05 16:16:43 +00:00
Richard W.M. Jones
c7b204bce3
daemon/device-name-translation.c: Fix btrfs volume reverse translation
...
Devices associated with btrfs volumes are not reverse-translated
(e.g., btrfsvol:/dev/sdX to sdY).
Forward translation occurs, creating a path mismatch. This causes
errors in subsequent btrfs commands.
Thanks: Arye Yurkovsky
2025-12-10 12:31:15 +00:00
Arye Yurkovsky
62b0e2ab64
daemon: lvm_utils: Further narrow stat failure to ENOENT
...
Missed the 2nd stat
2025-12-08 17:40:59 +00:00
Arye Yurkovsky
6aebf70e18
daemon: lvm_utils: Narrow stat failure to ENOENT
...
And remove redundant parantheses.
To only catch the failure we want to catch.
2025-12-08 17:40:59 +00:00
Arye Yurkovsky
c7228cd1ce
daemon: lvm_utils: Handle stat errors
...
lvm returns logical volumes even if they're broken, for instance when a
physical volume is missing in their volume group.
In such cases, stat would fail to resolve the provided path.
Handle such cases by skipping such failures when finding the matching
lvm device.
2025-12-08 17:40:59 +00:00
Richard W.M. Jones
c56e6ff39b
Version 1.57.7.
v1.57.7
2025-12-04 13:16:56 +00:00
Susant Sahani
3c73a71626
tests: drop test-btrfs-misc perl file
...
Fixes: commit c27f3d41b1
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-12-04 10:53:07 +00:00
Susant Sahani
1387e7f6a8
tests: nbd - convert to python
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-12-03 15:39:41 +00:00
Susant Sahani
fff03b7135
tests: selinux-label - convert to python
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-12-03 15:35:19 +00:00
Susant Sahani
1f739979bb
tests: lvm-mapping - convert to python
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-12-03 15:32:56 +00:00
Susant Sahani
8f187bf97b
tests: console-debug - convert to python
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-12-03 15:30:54 +00:00
Susant Sahani
bab46df1c6
tests: disk-labels - convert to python
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-12-03 15:29:26 +00:00
Susant Sahani
7f7eeb6668
tests: btrfs - subvolume-default convert to python
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-12-02 10:44:23 +00:00
Susant Sahani
c27f3d41b1
tests: btrfs - test-btrfs-misc convert to python
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-12-02 10:44:23 +00:00
Susant Sahani
7df1e9c359
tests: journal - convert to python
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-12-02 10:42:43 +00:00
Susant Sahani
817fb83742
tests: xfs - convert to python
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-12-02 10:37:05 +00:00
Susant Sahani
bd75288c5a
fuse: use modern sigaction initialization for ignored signals
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-12-01 16:28:12 +00:00
Susant Sahani
19c40e5f34
tests: tmpdirs - convert to python
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-12-01 16:17:19 +00:00
Richard W.M. Jones
40fdcd0146
fish: Fix const correctness in strrchr
...
In C23, strchr or strrchr on a const parameter now returns a const
pointer. We saw this error:
destpaths.c: In function ‘complete_dest_paths_generator’:
destpaths.c:165:9: error: assignment discards ‘const’ qualifier from pointer target type [-Werror=discarded-qualifiers]
165 | p = strrchr (text, '/');
| ^
2025-12-01 14:00:57 +00:00
Fco. Javier F. Serrador
fa7a18ed36
Translated using Weblate (Spanish)
...
Currently translated at 4.1% (551 of 13236 strings)
Translation: libguestfs/libguestfs-docs-master
Translate-URL: https://translate.fedoraproject.org/projects/libguestfs/libguestfs-docs-master/es/
Translated using Weblate (Spanish)
Currently translated at 62.8% (605 of 962 strings)
Translation: libguestfs/libguestfs-master
Translate-URL: https://translate.fedoraproject.org/projects/libguestfs/libguestfs-master/es/
2025-12-01 12:01:42 +00:00
Susant Sahani
4349548c83
lib/create: explicitly close fd and report close(2) errors
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-27 13:15:11 +00:00
Susant Sahani
192e086f66
lib/create: fix indentation in guestfs_impl_disk_create()
...
Convert tabs to spaces and align parameters correctly.
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-27 11:04:10 +00:00
Susant Sahani
a3a4fc2ba9
lib/create: use bool for is_power_of_2() return type
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-27 11:03:19 +00:00
Susant Sahani
60f60e9f4e
lib/create: use compound initializer for BLKDISCARD range
2025-11-27 11:02:06 +00:00
Susant Sahani
7d22402500
lib: Use bool type for allocated flag in disk creation
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-27 08:48:25 +00:00
Susant Sahani
3aaaf4f667
lib: Use compound initialization for buffer in disk creation
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-27 08:48:02 +00:00
Susant Sahani
cf6ac9aeba
lib: Add automatic file descriptor cleanup using CLEANUP_CLOSE attrib
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-27 08:46:51 +00:00
Susant Sahani
40e549294e
drives: Modernize guestfs_impl_add_drive_opts initialization
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-26 15:17:50 +00:00
Susant Sahani
b4d795c13d
lib: Modernize guestfs_int_drive_protocol_to_string to use static array
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-26 15:17:50 +00:00
Susant Sahani
19b208777a
fuse: Modernize mount_local_readdir with compound literal struct stat init
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-26 15:16:56 +00:00
Susant Sahani
257bfad817
appliance: Modernize guestfs_int_build_appliance with compound literal
...
No functional change.
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-26 15:15:33 +00:00
Susant Sahani
0a8d1aefef
daemon: tsk - Fix memory leak
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-24 11:15:23 +00:00
Susant Sahani
b5000cf547
daemon: send_dirent_info: Use designated compound literal for tsk_dirent
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-24 11:15:23 +00:00
Richard W.M. Jones
56da6b36d3
daemon: btrfs: Simplify snapshot code and fix invalid memory access
...
The existing code had a bug which you can demonstrate by doing:
$ guestfish -N fs:btrfs:10G -m /dev/sda1 \
btrfs-subvolume-create /sub :
btrfs-subvolume-snapshot /sub /snap1 : \
btrfs-subvolume-snapshot /sub /snap123 : \
btrfs-subvolume-snapshot /sub /snap123456 : \
btrfs-subvolume-show /sub
...
libguestfs: error: appliance closed the connection unexpectedly.
This usually means the libguestfs appliance crashed.
As the code for parsing the output and creating the comma-separated
list of snapshots was unncessarily complicated in the first place,
simplify it. This also fixes the bug.
This also adds a regression test.
Thanks: Arye Yurkovsky
Link: https://lists.libguestfs.org/archives/list/guestfs@lists.libguestfs.org/thread/QV5VDHIH7WRUNAE54K6OEOKJMWL6M7EM/
2025-11-24 10:44:44 +00:00
Susant Sahani
6c8e3992fc
fuse: Modernize mount_local_getattr with compound literal stat init
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-24 10:14:37 +00:00
Susant Sahani
b0f3d711cb
lib: fuse - Replace strdup + safe_malloc with safe_strdup/safe_memdup in copy_xattr_list
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-24 10:14:37 +00:00
Susant Sahani
c3ccd2164f
fuse: Modernize mount_local_statfs using compound literal statvfs init
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-24 10:14:37 +00:00
Susant Sahani
8ce7e08e1b
drive-create: Modernize create_drive_file using compound literal
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-24 10:09:03 +00:00
Susant Sahani
0bd33f87ce
daemon: stat_to_statns: Modernize with designated initializer
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-24 09:58:22 +00:00
Susant Sahani
0c437e52d6
daemon: bind_mount: Initialize struct bind_state with compound literal
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-24 09:58:05 +00:00
Susant Sahani
799b04fe3e
daemon: Convert do_set_uuid_random to table-driven dispatch
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-24 09:49:03 +00:00
Susant Sahani
174014933a
daemon: use table-driven dispatch in do_set_uuid
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-24 09:49:03 +00:00
Susant Sahani
301b9bc481
daemon: set-label: Convert to table-driven dispatch
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-24 09:47:21 +00:00
Susant Sahani
276897c4df
daemon: Use modern compound literal for SIGPIPE ignore
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-21 18:58:00 +00:00
Susant Sahani
25485036a6
fuse: Modernize SIGPIPE handler using compound literal
...
No functional change.
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-21 14:04:23 +00:00
Susant Sahani
4f19d68565
daemon: Use designated initializer for struct sockaddr_un
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-21 14:02:14 +00:00
Susant Sahani
3940b79041
parted: Modernize check_parttype() with table-driven mapping
...
Signed-off-by: Susant Sahani <ssahani@redhat.com >
2025-11-21 13:57:26 +00:00