search for: guestfs_int_recursive_remove_dir

Displaying 20 results from an estimated 22 matches for "guestfs_int_recursive_remove_dir".

2016 Jan 29
0
[PATCH 6/6] launch: avoid too long paths for sockets
...estfs_int_set_env_tmpdir (guestfs_h *g, const char *tmpdir); extern int guestfs_int_lazy_make_tmpdir (guestfs_h *g); +extern int guestfs_int_lazy_make_sockdir (guestfs_h *g); extern void guestfs_int_remove_tmpdir (guestfs_h *g); +extern void guestfs_int_remove_sockdir (guestfs_h *g); extern void guestfs_int_recursive_remove_dir (guestfs_h *g, const char *dir); /* whole-file.c */ @@ -782,6 +789,7 @@ extern void guestfs_int_launch_send_progress (guestfs_h *g, int perdozen); extern char *guestfs_int_appliance_command_line (guestfs_h *g, const char *appliance_dev, int flags); #define APPLIANCE_COMMAND_LINE_IS_TCG 1 cons...
2016 Feb 02
0
[PATCH 3/3] New API: get-sockdir
...t_set_env_runtimedir (guestfs_h *g, const char *runtimedir); extern int guestfs_int_lazy_make_tmpdir (guestfs_h *g); +extern int guestfs_int_lazy_make_sockdir (guestfs_h *g); extern void guestfs_int_remove_tmpdir (guestfs_h *g); +extern void guestfs_int_remove_sockdir (guestfs_h *g); extern void guestfs_int_recursive_remove_dir (guestfs_h *g, const char *dir); /* whole-file.c */ diff --git a/src/handle.c b/src/handle.c index 947818c..25d3c99 100644 --- a/src/handle.c +++ b/src/handle.c @@ -273,6 +273,10 @@ parse_environment (guestfs_h *g, return -1; } + str = do_getenv (data, "XDG_RUNTIME_DIR");...
2016 Feb 03
0
[PATCH v2 2/2] New API: get-sockdir
...t_set_env_runtimedir (guestfs_h *g, const char *runtimedir); extern int guestfs_int_lazy_make_tmpdir (guestfs_h *g); +extern int guestfs_int_lazy_make_sockdir (guestfs_h *g); extern void guestfs_int_remove_tmpdir (guestfs_h *g); +extern void guestfs_int_remove_sockdir (guestfs_h *g); extern void guestfs_int_recursive_remove_dir (guestfs_h *g, const char *dir); /* whole-file.c */ diff --git a/src/guestfs.pod b/src/guestfs.pod index a82d060..2a199c0 100644 --- a/src/guestfs.pod +++ b/src/guestfs.pod @@ -3482,6 +3482,17 @@ about kernel selection, see L<supermin(1)>. See L</LIBGUESTFS_CACHEDIR>, L</LIBGUE...
2016 Jan 29
7
[PATCH 1/6] launch: unix: check for length of sockets
Error out early if the path to the socket will not fit into sockaddr_un::sun_path, as we will not be able to connect to it. --- src/launch-unix.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/launch-unix.c b/src/launch-unix.c index 740c554..973e14b 100644 --- a/src/launch-unix.c +++ b/src/launch-unix.c @@ -47,6 +47,12 @@ launch_unix (guestfs_h *g, void *datav, const char
2016 Feb 03
4
[PATCH v2 1/2] launch: add internal helper for socket paths creation
Introduce an internal helper to create paths for sockets -- will be useful for changing later the logic for placing sockets. Futhermore, check that the length of sockets won't overflow the buffer for their filenames. --- src/guestfs-internal.h | 1 + src/launch-direct.c | 4 +++- src/launch-libvirt.c | 10 ++++++---- src/launch.c | 17 +++++++++++++++++ 4 files changed, 27
2016 Feb 02
6
[PATCH 1/3] launch: add internal helper for socket paths creation
Introduce an internal helper to create paths for sockets; will be useful for changing later the logic for placing sockets. --- src/guestfs-internal.h | 1 + src/launch-direct.c | 4 +++- src/launch-libvirt.c | 10 ++++++---- src/launch.c | 15 +++++++++++++++ 4 files changed, 25 insertions(+), 5 deletions(-) diff --git a/src/guestfs-internal.h b/src/guestfs-internal.h index
2016 Jan 29
1
Re: [PATCH 6/6] launch: avoid too long paths for sockets
...(guestfs_h *g, const char *tmpdir); > extern int guestfs_int_lazy_make_tmpdir (guestfs_h *g); > +extern int guestfs_int_lazy_make_sockdir (guestfs_h *g); > extern void guestfs_int_remove_tmpdir (guestfs_h *g); > +extern void guestfs_int_remove_sockdir (guestfs_h *g); > extern void guestfs_int_recursive_remove_dir (guestfs_h *g, const char *dir); > > /* whole-file.c */ > @@ -782,6 +789,7 @@ extern void guestfs_int_launch_send_progress (guestfs_h *g, int perdozen); > extern char *guestfs_int_appliance_command_line (guestfs_h *g, const char *appliance_dev, int flags); > #define APPLIANCE_CO...
2016 May 12
0
[PATCH 2/4] src/tmpdirs.c: Add internal documentation.
...9;s a temporary directory so it'll eventually be cleaned - * up by a temp cleaner). This is done using "rm -rf" because that's - * simpler and safer. + * up by a temp cleaner). + * + * This is implemented using C<rm -rf> because that's simpler and + * safer. */ void guestfs_int_recursive_remove_dir (guestfs_h *g, const char *dir) -- 2.7.4
2016 May 12
0
[PATCH 3/4] appliance: Move code for creating supermin appliance directory to tmpdirs.c.
...estfs_int_lazy_make_tmpdir (guestfs_h *g); extern int guestfs_int_lazy_make_sockdir (guestfs_h *g); +extern char *guestfs_int_lazy_make_supermin_appliance_dir (guestfs_h *g); extern void guestfs_int_remove_tmpdir (guestfs_h *g); extern void guestfs_int_remove_sockdir (guestfs_h *g); extern void guestfs_int_recursive_remove_dir (guestfs_h *g, const char *dir); diff --git a/src/tmpdirs.c b/src/tmpdirs.c index 293e4ea..6c8fe0d 100644 --- a/src/tmpdirs.c +++ b/src/tmpdirs.c @@ -213,6 +213,61 @@ guestfs_int_lazy_make_sockdir (guestfs_h *g) } /** + * Create the supermin appliance directory under cachedir, if it does + * no...
2017 Jul 14
0
[PATCH 12/27] daemon: Reimplement ‘file_architecture’ API in OCaml.
..._regular_file (bin)) { - bool loading_ok, matched; - - ret = magic_for_file (g, bin, &loading_ok, &matched); - if (!loading_ok || matched) - goto out; - } - } - error (g, "file_architecture: could not determine architecture of cpio archive"); - - out: - guestfs_int_recursive_remove_dir (g, dir); - - return ret; -} - -static char * -compressed_file_arch (guestfs_h *g, const char *path, const char *method) -{ - CLEANUP_FREE char *tmpdir = guestfs_get_tmpdir (g), *dir = NULL; - CLEANUP_FREE char *tempfile = NULL, *tempfile_extracted = NULL; - CLEANUP_CMD_CLOSE struct command *cm...
2016 May 12
7
[PATCH 0/4] lib: qemu: Memoize qemu feature detection.
Doing qemu feature detection in the direct backend takes ~100ms because we need to run `qemu -help' and `qemu -devices ?', and each of those interacts with glibc's very slow link loader. Fixing the link loader is really hard. Instead memoize the output of those two commands. This patch series first separates all the code dealing with qemu into a separate module (src/qemu.c) and
2015 Sep 29
8
[PATCH 0/7] copy-in/copy-out: Capture errors from tar subprocess (RHBZ#1267032).
Commits 3c27f3d91e1566854747bbe844186783fc84f3a8 and 1b6f0daa9ae7fcc94e389232d0c397816cda973d added an internal API for running commands asynchronously. It is only used by the copy-in and copy-out APIs. Unfortunately this made the command code very complex: it was almost impossible to redirect stderr to a file, and there were a lot of long-range dependencies through the file. It was also buggy:
2017 Jun 03
12
[PATCH v2 00/12] Allow APIs to be implemented in OCaml.
Version 1 was here: https://www.redhat.com/archives/libguestfs/2017-June/msg00003.html This patch series reimplements a few more APIs in OCaml, including some very important core APIs like ?list_filesystems? and ?mount?. All the tests pass after this. The selection of APIs that I have moved may look a little random, but in fact they are all APIs consumed by the inspection code (and some more
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.
2017 Jun 05
19
[PATCH v3 00/19] Allow APIs to be implemented in OCaml.
v2 was here: https://www.redhat.com/archives/libguestfs/2017-June/msg00008.html This series gets as far as a working (and faster) reimplementation of ‘guestfs_list_filesystems’. I also have another patch series on top of this one which reimplements the inspection APIs inside the daemon, but that needs a bit more work still, since inspection turns out to be a very large piece of code. Rich.
2017 Jul 27
23
[PATCH v3 00/23] Reimplement many daemon APIs in OCaml.
I think this fixes everything mentioned: - Added the Optgroups module as suggested. - Remove command temporary files. - Replace command ~flags with ?fold_stdout_on_stderr. - Nest _with_mounted function. - Rebase & retest. Rich.
2017 Jul 21
27
[PATCH v2 00/23] Reimplement many daemon APIs in OCaml.
v1 was posted here: https://www.redhat.com/archives/libguestfs/2017-July/msg00098.html This series now depends on two small patches which I posted separately: https://www.redhat.com/archives/libguestfs/2017-July/msg00207.html https://www.redhat.com/archives/libguestfs/2017-July/msg00209.html v1 -> v2: - Previously changes to generator/daemon.ml were made incrementally through the patch
2017 Jul 14
45
[PATCH 00/27] Reimplement many daemon APIs in OCaml.
Previously posted as part of the mega utilities/inspection series here: https://www.redhat.com/archives/libguestfs/2017-June/msg00232.html What I've done is to extract just the parts related to rewriting daemon APIs in OCaml, rebase them on top of the current master, fix a few things, and recompile and test everything. Rich.
2017 Jun 12
32
[PATCH v5 00/32] Refactor utilities, implement some APIs in OCaml.
This is a combination of: https://www.redhat.com/archives/libguestfs/2017-June/msg00046.html [PATCH 00/12] Refactor utility functions. plus: https://www.redhat.com/archives/libguestfs/2017-June/msg00023.html [PATCH v3 00/19] Allow APIs to be implemented in OCaml. with the second patches rebased on top of the utility refactoring, and some other adjustments and extensions. This passes
2017 Jun 19
29
[PATCH v7 00/29] Reimplement inspection in the daemon.
v6 was posted here: https://www.redhat.com/archives/libguestfs/2017-June/msg00103.html and this requires the utilities refactoring posted here: https://www.redhat.com/archives/libguestfs/2017-June/msg00169.html Inspection is now complete[*], although not very well tested. I'm intending to compare the output of many guests using old & new virt-inspector to see if I can find any