search for: guestfs_int_split_str

Displaying 20 results from an estimated 31 matches for "guestfs_int_split_str".

2019 Nov 26
0
[PATCH common v2 1/3] options: Simplify selector parsing for --key options.
Refactor this code to use guestfs_int_split_string function which slightly simplifies it. This should have no effect. --- options/keys.c | 35 ++++++++++++++--------------------- 1 file changed, 14 insertions(+), 21 deletions(-) diff --git a/options/keys.c b/options/keys.c index f783066..74b5497 100644 --- a/options/keys.c +++ b/options/keys....
2023 Jan 30
1
[p2v PATCH 09/11] gui: expose "p2v.output.misc" (-oo)
On Mon, Jan 30, 2023 at 03:22:26PM +0100, Laszlo Ersek wrote: > + str = gtk_entry_get_text (GTK_ENTRY (oo_entry)); > + guestfs_int_free_string_list (config->output.misc); > + config->output.misc = guestfs_int_split_string (',', str); My concern here is that someone is going to put "foo=bar, baz=1" in this field, and it will improperly split above. So maybe a bit of trimming on the resulting array? > + if (config->output.misc == NULL) > + error (EXIT_FAILURE, errno, "strdup&q...
2019 Nov 26
6
[PATCH options v2 0/3] options: Allow multiple and default --key parameters.
v1: https://www.redhat.com/archives/libguestfs/2019-November/msg00036.html
2019 Dec 20
3
[common/libguestfs PATCH 0/2] Fix OCaml/Python linking
Make sure they can build also in no as-neede setups. Pino Toscano (1): utils: split string list functions in own file build: use split stringlist functions from common/utils utils/Makefile.am | 2 + utils/guestfs-stringlists-utils.h | 30 +++++ utils/guestfs-utils.h | 7 +- utils/stringlists-utils.c | 197 ++++++++++++++++++++++++++++++ utils/utils.c
2019 Nov 12
0
[PATCH 2/2] options: Allow multiple --key parameters and default keys.
...key_store_add_from_selector (struct key_store *ks, const char *selector_orig) +key_store_add_from_selector (struct key_store *ks, const char *selector) { - CLEANUP_FREE char *selector = strdup (selector_orig); - const char *elem; - char *saveptr; + CLEANUP_FREE_STRING_LIST char **fields = + guestfs_int_split_string (':', selector); struct key_store_key key; - if (!selector) - error (EXIT_FAILURE, errno, "strdup"); + if (!fields) + error (EXIT_FAILURE, errno, "guestfs_int_split_string"); - /* 1: device */ - elem = strtok_r (selector, ":", &saveptr);...
2019 Nov 12
4
[PATCH 1/2] options: Fixes and enhancements to --key parsing.
The first patch fixes a rather serious bug, the second patch allows multiple --key parameters and default parameters. There is a third patch to libguestfs which adds a test, coming up. I did not yet review and fix the documentation. I think we need to centralize it in one place because at the moment the same documentation for --key is copy/pasted all over the tools. Rich.
2015 Jul 01
1
[PATCH 1/2] utils: Add a test of the guestfs_int_drive_name function.
This function didn't have a unit test before. --- src/test-utils.c | 29 ++++++++++++++++++++++++++++- 1 file changed, 28 insertions(+), 1 deletion(-) diff --git a/src/test-utils.c b/src/test-utils.c index 8e1491f..c5e2f08 100644 --- a/src/test-utils.c +++ b/src/test-utils.c @@ -1,5 +1,5 @@ /* libguestfs - * Copyright (C) 2014 Red Hat Inc. + * Copyright (C) 2014-2015 Red Hat Inc. * *
2015 Jul 01
2
[PATCH v2 0/2] utils: Add guestfs_int_drive_index and unit test.
Since v1: - Test error cases in the unit test of guestfs_int_drive_index. Rich.
2023 Jan 30
11
[p2v PATCH 00/11] Expose virt-v2v's "-oo"; re-enable openstack
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1792141 Let the user pass "-oo" options from the kernel cmdline and from the GUI to virt-v2v. This is primarily useful with the OpenStack output mode, so reenable that mode. Cc: Alban Lecorps <alban.lecorps at ubisoft.com> Laszlo Alban Lecorps (1): Introduce "p2v.output.misc" for passing "-oo" options
2016 May 17
2
[PATCH 0/2] Use -bios bios-fast.bin where supported.
NOTE: Not for upstream, yet. This depends on 3 non-upstream patches. - The qemu rework in libguestfs, which in turn depends on what Pino is up to. - Support for '-L ?' in qemu: https://lists.gnu.org/archive/html/qemu-devel/2016-05/threads.html#02596 - Support for bios-fast.bin in qemu: https://lists.gnu.org/archive/html/qemu-devel/2016-05/threads.html#02408 This commit
2016 May 18
2
[PATCH v2 0/2] Use -bios bios-fast.bin where supported.
This commit uses -bios bios-fast.bin if available, which basically stops SeaBIOS from trying to do PCI probing during boot, which is a waste of time when using the -kernel option. v1 -> v2: - Rebase on top of Pino's work. This still has 3 dependencies: - The qemu memoization work (v2). - Support for '-L ?' in qemu:
2018 Jun 29
3
p2v: Various cleanups.
These are a prelude to fixing https://bugzilla.redhat.com/show_bug.cgi?id=1590220 A lot of the virt-p2v configuration code was duplicated manually. These changes make sure that most of it is generated. Rich.
2017 Feb 03
5
[PATCH 0/5] Support socket activation in virt-p2v.
As the subject says, support socket activation in virt-p2v. I have added upstream support for socket activation to nbdkit already: https://github.com/libguestfs/nbdkit/commit/7ff39d028c6359f5c0925ed2cf4a2c4c751af2e4 I posted a patch for qemu-nbd, still waiting on more reviews for that one: https://www.mail-archive.com/qemu-devel@nongnu.org/msg427246.html I tested this against old and new qemu
2015 Feb 14
2
[PATCH 0/2] Change guestfs__*
libguestfs has used double and triple underscores in identifiers. These aren't valid for global names in C++. (http://stackoverflow.com/a/228797) These large but completely mechanical patches change the illegal identifiers to legal ones. Rich.
2016 May 25
4
[PATCH 0/4] qemu: Use sqlite to store qemu detection data.
Patches 1 & 2 were posted previously here: https://www.redhat.com/archives/libguestfs/2016-May/msg00134.html Patch 3 is a hack so I can test this using my own version of qemu (the `-L ?' stuff is not upstream). Patch 4 is where the real action takes place: Replace the caching of qemu features in blob-like files with a sqlite database. Probably the best way to approach this patch is to
2019 Jul 01
0
[PATCH 1/6] p2v: move kernel config to perl script
...tf $fh " \"%s\", p);\n", $key; + print $fh " }\n"; + } elsif ($type eq 'ConfigStringList') { + printf $fh " guestfs_int_free_string_list (%s%s);\n", $v, $field->name; + printf $fh " %s%s = guestfs_int_split_string (',', p);\n", $v, $field->name; + printf $fh " if (%s%s == NULL)\n", $v, $field->name; + print $fh " error (EXIT_FAILURE, errno, \"strdup\");\n"; + } + + print $fh " }\n"; + print $fh &quot...
2017 Jan 26
3
[PATCH 0/3] p2v: Allow nbdkit as an alternative NBD server.
qemu-nbd is a fine NBD server. However it's not easy to compile a reliably working version on RHEL 5. This patch series allows nbdkit to be used as an alternative (qemu-nbd is still the default). Rich.
2019 Jul 01
8
[PATCH 0/6] p2v: start making it independent
As preliminary steps in splitting virt-p2v to an own repository, start making p2v more independent within libguestfs. This is accomplished by the following changes: - generate the p2v kernel config sources & docs at build time using a Perl script, rather than the generator (so no need for OCaml when building from git, and no generated sources in dist tarballs) - create two local test
2017 Jun 15
0
[PATCH v6 11/41] utils: Rename ‘guestfs-internal-frontend.h’ to ‘utils.h’.
...ests.c b/lib/unit-tests.c index d44bc41e0..a9ba4cbc2 100644 --- a/lib/unit-tests.c +++ b/lib/unit-tests.c @@ -38,7 +38,7 @@ #include "guestfs.h" #include "guestfs-internal.h" -#include "guestfs-internal-frontend.h" +#include "utils.h" /** * Test C<guestfs_int_split_string>. diff --git a/make-fs/make-fs.c b/make-fs/make-fs.c index e30745a0f..103dbebd1 100644 --- a/make-fs/make-fs.c +++ b/make-fs/make-fs.c @@ -35,7 +35,7 @@ #include <sys/wait.h> #include "guestfs.h" -#include "guestfs-internal-frontend.h" +#include "utils.h&quo...
2017 Jun 19
0
[PATCH v7 12/13] utils: Rename ‘guestfs-internal-frontend.h’ to ‘guestfs-utils.h’.
.../lib/unit-tests.c index d44bc41e0..67a174f51 100644 --- a/lib/unit-tests.c +++ b/lib/unit-tests.c @@ -38,7 +38,7 @@ #include "guestfs.h" #include "guestfs-internal.h" -#include "guestfs-internal-frontend.h" +#include "guestfs-utils.h" /** * Test C<guestfs_int_split_string>. diff --git a/make-fs/make-fs.c b/make-fs/make-fs.c index e30745a0f..7b99280d9 100644 --- a/make-fs/make-fs.c +++ b/make-fs/make-fs.c @@ -35,7 +35,7 @@ #include <sys/wait.h> #include "guestfs.h" -#include "guestfs-internal-frontend.h" +#include "guestfs-uti...