search for: unix_util

Displaying 20 results from an estimated 125 matches for "unix_util".

Did you mean: unix_utils
2017 Mar 13
2
[PATCH] mllib: Add a binding for realpath(3).
I was planning to use this function to harden the code in v2v/input_ova.ml against malicious OVA files. However I didn't complete that work. Hate to see a good commit go to waste ... Rich.
2017 Mar 13
0
[PATCH] mllib: Add a binding for realpath(3).
This is a copy of the supermin binding: https://github.com/libguestfs/supermin/tree/master/src realpath* --- mllib/unix_utils-c.c | 18 ++++++++++++++++++ mllib/unix_utils.ml | 4 ++++ mllib/unix_utils.mli | 5 +++++ 3 files changed, 27 insertions(+) diff --git a/mllib/unix_utils-c.c b/mllib/unix_utils-c.c index f5aaaf6..7e90541 100644 --- a/mllib/unix_utils-c.c +++ b/mllib/unix_utils-c.c @@ -25,6 +25,7 @@ #include...
2020 Sep 18
0
[PATCH common] mlutils: Simple wrapper around sysconf (_SC_NPROCESSORS_ONLN).
--- mlutils/unix_utils-c.c | 15 +++++++++++++++ mlutils/unix_utils.ml | 5 +++++ mlutils/unix_utils.mli | 9 +++++++++ 3 files changed, 29 insertions(+) diff --git a/mlutils/unix_utils-c.c b/mlutils/unix_utils-c.c index 3309961..8acf039 100644 --- a/mlutils/unix_utils-c.c +++ b/mlutils/unix_utils-c.c @@ -77,6 +77,7...
2017 Oct 11
1
[PATCH] common/mlutils: fix f_type comparisons
statfs::f_type is usually a signed type, so cast it to unsigned to check its value against magic values of filesystems. --- common/mlutils/unix_utils-c.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/common/mlutils/unix_utils-c.c b/common/mlutils/unix_utils-c.c index f8c4f8abe..2afdc9e5f 100644 --- a/common/mlutils/unix_utils-c.c +++ b/common/mlutils/unix_utils-c.c @@ -357,9 +357,9 @@ guestfs_int_mllib_statvfs_is_net...
2017 Oct 03
4
[PATCH v2 0/2] builder: Choose better weights in the planner.
v1 -> v2: - Removed the f_type field from StatVFS.statvfs structure. - New function StatVFS.filesystem_is_remote, written in C. [Thinking about it, this should probably be called ?is_network_filesystem?, but I can change that before pushing]. - Use statvfs instead of fstatvfs, and statfs instead of fstatfs. - Rejigged the comments in builder/builder.ml to make them simpler
2017 Oct 03
0
[PATCH v2 2/2] builder: Choose better weights in the planner.
--- builder/builder.ml | 84 +++++++++++++++++++++++++++++++++---------- common/mlutils/unix_utils-c.c | 27 ++++++++++++++ common/mlutils/unix_utils.ml | 3 ++ common/mlutils/unix_utils.mli | 4 +++ m4/guestfs_libraries.m4 | 1 + 5 files changed, 100 insertions(+), 19 deletions(-) diff --git a/builder/builder.ml b/builder/builder.ml index d8e625f68..fd19aa7d9 100644 --- a/builder/bu...
2017 Oct 04
2
[PATCH v3 0/2] builder: Choose better weights in the planner.
v2 -> v3: - Drop gnulib fallback.
2017 Feb 22
4
[PATCH 0/3] v2v: vCenter: Remove proxy environment variables
Fix for: https://bugzilla.redhat.com/show_bug.cgi?id=1354507 Main explanation is in patch #3. Rich.
2017 Oct 02
3
[PATCH 0/2] builder: Choose better weights in the planner.
It started out as "this'll be just a simple fix ..." and turned into something a bit over-engineered in the end. Here it is anyway. Rich.
2017 Oct 03
0
[PATCH v2 1/2] daemon: Reimplement statvfs API in OCaml.
common/mlutils: Unix_utils.StatVFS.statvfs: This commit implements a full-featured binding for the statvfs(3) function. We then use this to reimplement the daemon statvfs API in OCaml. Note that the Gnulib fallback is fixed in this commit. It previously referenced non-existent field names in the fs_usage struct. --- com...
2017 Jun 15
0
[PATCH v6 10/41] mllib, v2v: Split out OCaml utils bindings ‘common/mlutils’.
Create a module ‘C_utils’ containing functions like ‘drive_name’ and ‘shell_unquote’ which come from the C utilities. The new directory ‘common/mlutils’ also contains the ‘Unix_utils’ wrappers around POSIX functions missing from the OCaml stdlib. --- .gitignore | 3 + Makefile.am | 24 ++--- builder/Makefile.am | 6 +- common/mlutils/Makefile.am | 156 +++++++++++++++...
2017 Jun 03
3
[PATCH 0/3]: daemon: Reimplement ‘file’ API in OCaml.
This patch series is just FYI at the moment. However it does pass the tests. The daemon is a self-contained program. We don't need to write it all in C. Writing parts of it in OCaml would make it simpler and less error-prone. In particular if the daemon was written in a more sane programming language then we could move the inspection code to run entirely inside the appliance, which would
2018 May 15
3
[PATCH v2 0/2] Fix building on macOS
v1 was here: https://www.redhat.com/archives/libguestfs/2018-May/msg00042.html v2: - Split into two patches dealing with the different issues. - git format & attribution. I only tested this on Linux but at least it doesn't break things there. Rich.
2017 Oct 04
2
Re: [PATCH v2 2/2] builder: Choose better weights in the planner.
On Tuesday, 3 October 2017 14:24:14 CEST Richard W.M. Jones wrote: > --- > builder/builder.ml | 84 +++++++++++++++++++++++++++++++++---------- Cannot comment on the actual logic in the planner, since I admit I did not have an in-depth look at it. > diff --git a/common/mlutils/unix_utils-c.c b/common/mlutils/unix_utils-c.c > index 657852ef2..340fdec44 100644 > --- a/common/mlutils/unix_utils-c.c > +++ b/common/mlutils/unix_utils-c.c > @@ -28,10 +28,18 @@ > #include <errno.h> > #include <sys/types.h> > > +#ifdef HAVE_SYS_STATFS_H > +#inclu...
2017 Mar 01
2
[PATCH libguestfs] Use AC_HEADER_MAJOR to find definitions of major, minor, makedev.
...cent than Sep 2016) which corrects the AC_HEADER_MAJOR macro in a similar way. --- bootstrap | 1 + cat/ls.c | 7 +++++++ daemon/mknod.c | 6 ++++++ diff/diff.c | 7 +++++++ lib/fuse.c | 6 ++++++ m4/guestfs_libraries.m4 | 3 +++ mllib/unix_utils-c.c | 8 +++++++- p2v/main.c | 6 ++++++ 8 files changed, 43 insertions(+), 1 deletion(-) diff --git a/bootstrap b/bootstrap index 037d07e..faa10a3 100755 --- a/bootstrap +++ b/bootstrap @@ -92,6 +92,7 @@ strerror strndup symlinkat sys_select +sys_types sys_wait vasprintf vc...
2018 May 07
3
[PATCH] Fix building on macOS
Hello, I have attached a patch that allowed the build to complete successfully on macOS. I haven't tried building the daemon under macOS, but I patched two files there in a similar manner to some of the other files for consistency (just the include order for rpc headers). Thanks, Adam Robinson Virtualization and Cloud Infrastructure Senior Information and Technology Services University of
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
2017 Jun 16
1
Re: [PATCH v6 10/41] mllib, v2v: Split out OCaml utils bindings ‘common/mlutils’.
On Thursday, 15 June 2017 19:06:00 CEST Richard W.M. Jones wrote: > Create a module ‘C_utils’ containing functions like ‘drive_name’ and > ‘shell_unquote’ which come from the C utilities. > > The new directory ‘common/mlutils’ also contains the ‘Unix_utils’ > wrappers around POSIX functions missing from the OCaml stdlib. > --- I fear we are spreading the code among too many helper libraries... Why not just add these small bindings to Common_utils directly? -- Pino Toscano
2018 May 07
1
[PATCH] daemon: tweak regexp for file type detection (RHBZ#1575640)
...string will follow - the architecture string has no commas --- daemon/filearch.ml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/daemon/filearch.ml b/daemon/filearch.ml index b2c30ae87..a892ba851 100644 --- a/daemon/filearch.ml +++ b/daemon/filearch.ml @@ -25,7 +25,7 @@ open Unix_utils open Utils let re_file_elf = - PCRE.compile "ELF (\\d+)-bit (MSB|LSB).*(?:executable|shared object|relocatable), (.+?)," + PCRE.compile "ELF (\\d+)-bit (MSB|LSB).*(?:executable|shared object|relocatable)(?:,)? ([^,]+?)," let re_file_elf_ppc64 = PCRE.compile ".*64....
2019 Dec 18
1
[PATCH] po: reduce the list of extracted sources
...e/dummy.c common/mlpcre/pcre-c.c common/mlprogress/progress-c.c -common/mlstdutils/dummy.c common/mltools/JSON_parser-c.c -common/mltools/dummy.c common/mltools/getopt-c.c common/mltools/tools_utils-c.c common/mltools/uri-c.c common/mlutils/c_utils-c.c -common/mlutils/dummy.c common/mlutils/unix_utils-c.c -common/mlvisit/dummy.c common/mlvisit/visit-c.c common/mlxml/xml-c.c common/options/config.c @@ -43,7 +35,6 @@ common/parallel/domains.c common/parallel/estimate-max-threads.c common/parallel/parallel.c common/progress/progress.c -common/qemuopts/qemuopts-tests.c common/qemuopts/qemuop...