search for: guestfs_int_safe_malloc

Displaying 9 results from an estimated 9 matches for "guestfs_int_safe_malloc".

2016 Feb 05
7
[PATCH 0/7] lib: Stop exporting the safe_malloc, etc. functions.
The safe_malloc (etc) functions call g->abort_fn on failure. That's not appropriate for language bindings, and we never intended that these internal functions be used from language bindings, that was just a historical accident. This patch series removes any external use of the safe_* functions. Rich.
2015 Oct 06
0
[PATCH 1/4] ocaml: Use generational global roots.
...ational_global_root (roots[i]); free (roots[i]); } free (roots); - caml_remove_global_root (v); + caml_remove_generational_global_root (v); free (v); } } @@ -179,10 +179,7 @@ ocaml_guestfs_create (value environmentv, value close_on_exitv, value unitv) */ v = guestfs_int_safe_malloc (g, sizeof *v); *v = gv; - /* XXX This global root is generational, but we cannot rely on every - * user having the OCaml 3.11 version which supports this. - */ - caml_register_global_root (v); + caml_register_generational_global_root (v); guestfs_set_private (g, "_ocaml_g",...
2017 Aug 17
0
Re: libguestfs binaries missing when built from source code
...> libguestfs: trace: set_verbose = 0 > libguestfs: trace: set_path "/opt/libguestfs/x86_64/1.30.3/lib/guestfs/appliance:" > libguestfs: trace: set_path = 0 > libguestfs: create: flags = 0, handle = 0xfa6c90 > virt-resize: symbol lookup error: virt-resize: undefined symbol: guestfs_int_safe_malloc No, it looks like the version of libguestfs (the shared library) and the tools are not in sync. Did you install it from sources, or from self-built packages? -- Pino Toscano
2015 Oct 06
6
[PATCH 0/4] ocaml: Allow Guestfs.t handle to be garbage collected.
Allow Guestfs.t handle to be garbage collected, and add a regression test.
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.
2015 Oct 20
3
[PATCH 1/2] generator: add a RelativePathnameList parameter type
...pr " %s_size = (*env)->GetArrayLength (env, j%s);\n" n n - | StringList n | DeviceList n -> + | StringList n | DeviceList n | RelativePathnameList n -> pr " %s_len = (*env)->GetArrayLength (env, j%s);\n" n n; pr " %s = guestfs_int_safe_malloc (g, sizeof (char *) * (%s_len+1));\n" n n; pr " for (i = 0; i < %s_len; ++i) {\n" n; @@ -1044,7 +1044,7 @@ get_all_event_callbacks (guestfs_h *g, size_t *len_rtn) pr " (*env)->ReleaseStringUTFChars (env, j%s, %s);\n" n n | Buffer...
2015 Oct 21
2
[PATCH 1/2] generator: add a FilenameList parameter type
...pr " %s_size = (*env)->GetArrayLength (env, j%s);\n" n n - | StringList n | DeviceList n -> + | StringList n | DeviceList n | FilenameList n -> pr " %s_len = (*env)->GetArrayLength (env, j%s);\n" n n; pr " %s = guestfs_int_safe_malloc (g, sizeof (char *) * (%s_len+1));\n" n n; pr " for (i = 0; i < %s_len; ++i) {\n" n; @@ -1044,7 +1044,7 @@ get_all_event_callbacks (guestfs_h *g, size_t *len_rtn) pr " (*env)->ReleaseStringUTFChars (env, j%s, %s);\n" n n | Buffer...
2015 Oct 05
0
[PATCH 2/2] Fix whitespace.
..., + unsigned int proc_nr, unsigned int serial) { if (hdr->prog != GUESTFS_PROGRAM) { error (g, "wrong program (%u/%d)", hdr->prog, GUESTFS_PROGRAM); diff --git a/src/alloc.c b/src/alloc.c index 866eb21..7b17cc5 100644 --- a/src/alloc.c +++ b/src/alloc.c @@ -46,8 +46,8 @@ guestfs_int_safe_malloc (guestfs_h *g, size_t nbytes) sizeof (ptrdiff_t) <= sizeof (size_t), so do not bother to test for exactly-SIZE_MAX allocations on such hosts; this avoids a test and branch when S is known to be 1. */ -# define xalloc_oversized(n, s) \ - ((size_t) (sizeof (ptrdiff_t) <= sizeof...
2015 Oct 05
3
[PATCH 1/2] Change 'fprintf (stdout,...)' -> printf.
Result of earlier copy and paste. --- align/scan.c | 35 ++++++++++--------- cat/cat.c | 39 +++++++++++---------- cat/filesystems.c | 69 +++++++++++++++++++------------------- cat/log.c | 35 ++++++++++--------- cat/ls.c | 61 +++++++++++++++++---------------- df/main.c | 43 ++++++++++++------------ diff/diff.c | 67