Displaying 4 results from an estimated 4 matches for "guestfs_int_cmd_set_child_callback".
2015 May 26
0
[PATCH] lib: Limit space and time used by 'qemu-img info' subprocess.
...truct command
{
guestfs_h *g;
@@ -139,6 +152,9 @@ struct command
cmd_child_callback child_callback;
void *child_callback_data;
+ /* Optional child limits. */
+ struct child_rlimits *child_rlimits;
+
/* Optional stdin forwarding to the child. */
int infd;
};
@@ -329,6 +345,22 @@ guestfs_int_cmd_set_child_callback (struct command *cmd,
cmd->child_callback_data = data;
}
+/* Set up child rlimits, in case the process we are running could
+ * consume lots of space or time.
+ */
+void
+guestfs_int_cmd_set_child_rlimit (struct command *cmd, int resource, long limit)
+{
+ struct child_rlimits *p;
+
+ p...
2023 Jul 11
1
[libguestfs PATCH] lib: remove guestfs_int_cmd_clear_close_files()
...guestfs_int_cmd_set_stderr_to_stdout (struct command *);
extern void guestfs_int_cmd_set_child_rlimit (struct command *, int resource, long limit);
extern void guestfs_int_cmd_clear_capture_errors (struct command *);
-extern void guestfs_int_cmd_clear_close_files (struct command *);
extern void guestfs_int_cmd_set_child_callback (struct command *, cmd_child_callback child_callback, void *data);
extern int guestfs_int_cmd_run (struct command *);
extern void guestfs_int_cmd_close (struct command *);
diff --git a/lib/command.c b/lib/command.c
index 515ef624bd96..82a47bafa9e5 100644
--- a/lib/command.c
+++ b/lib/command.c
@@...
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:
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.