search for: caml_raise_not_found

Displaying 12 results from an estimated 12 matches for "caml_raise_not_found".

2015 Oct 13
6
[PATCH 0/4] rpm: Choose providers better (RHBZ#1266918).
Fix for https://bugzilla.redhat.com/show_bug.cgi?id=1266918
2020 Aug 05
1
[v2v PATCH] libosinfo: remove auto-cleanup for OsinfoList
...lue dbv, value osv) osinfo_filter_add_constraint (filter, OSINFO_PRODUCT_PROP_SHORT_ID, String_val (osv)); list = osinfo_list_new_filtered (OSINFO_LIST(os_list), filter); - if (osinfo_list_get_length (list) == 0) + if (osinfo_list_get_length (list) == 0) { + g_object_unref (list); caml_raise_not_found (); + } os = OSINFO_OS(osinfo_list_get_nth (list, 0)); rv = Val_OsinfoOs_t (dbv, os); + g_object_unref (list); CAMLreturn (rv); } -- 2.26.2
2017 Sep 22
0
[PATCH v3 01/22] common/mlpcre: Raise Invalid_argument if PCRE.sub n parameter is negative.
..., Int_val (nv), - (const char **) &str); + if (n < 0) + caml_invalid_argument ("PCRE.sub: n must be >= 0"); + + len = pcre_get_substring (m->subject, m->vec, m->r, n, (const char **) &str); if (len == PCRE_ERROR_NOSUBSTRING) caml_raise_not_found (); diff --git a/common/mlpcre/pcre_tests.ml b/common/mlpcre/pcre_tests.ml index e5214eab8..2b18f462f 100644 --- a/common/mlpcre/pcre_tests.ml +++ b/common/mlpcre/pcre_tests.ml @@ -69,6 +69,13 @@ let () = | PCRE.Error (msg, code) -> failwith (sprintf "PCRE error: %s (PCRE error cod...
2014 Sep 17
4
[PATCH 0/2] supermin: use librpm for rpm support
Hi, this work makes supermin use the rpm library instead of invoking rpm directly. This, together with a needed refactoring of the dependency resolution, should help in make supermin faster on rpm-based systems. Surely the patches will still need polishing, especially for behaviours of newly added stuff, but at least it's a good starting point. Noting that you need rpm-devel on most of rpm
2017 Sep 20
4
[PATCH 0/4] Replace some uses of the Str module with PCRE.
Str is a pretty ugly regexp module. Let's try to replace it with PCRE. This series of commits goes some small way towards that eventual goal. - - - I wonder if there was a deep reason why we had this? let unix2dos s = String.concat "\r\n" (Str.split_delim (Str.regexp_string "\n") s) I replaced it with what I think should be (nearly) equivalent: let unix2dos s =
2017 Sep 22
0
[PATCH v3 02/22] common/mlpcre: Add PCRE.subi to return indexes instead of the substring.
...raise_pcre_error ("PCRE.subi called without calling PCRE.matches", 0); + + if (n < 0) + caml_invalid_argument ("PCRE.subi: n must be >= 0"); + + /* eg if there are 2 captures, m->r == 3, and valid values of n are + * 0, 1 or 2. + */ + if (n >= m->r) + caml_raise_not_found (); + + rv = caml_alloc (2, 0); + Store_field (rv, 0, Val_int (m->vec[n*2])); + Store_field (rv, 1, Val_int (m->vec[n*2+1])); + + CAMLreturn (rv); +} diff --git a/common/mlpcre/pcre_tests.ml b/common/mlpcre/pcre_tests.ml index 2b18f462f..316a4348e 100644 --- a/common/mlpcre/pcre_tests.ml...
2020 Jan 22
4
[v2v PATCH 0/3] Use libosinfo for query device drivers
This patch series integrates libosinfo in virt-v2v to get the list of files for Windows from libosinfo, if possible. The actual data is still from virtio-win, just unpacked. Pino Toscano (3): build: require libosinfo v2v: add a minimal libosinfo interface v2v: try to get windows driver files from libosinfo m4/guestfs-v2v.m4 | 3 + v2v/Makefile.am | 9 +-
2020 Jan 28
4
[v2v PATCH v2 0/3] Use libosinfo for query device drivers
This patch series integrates libosinfo in virt-v2v to get the list of files for Windows from libosinfo, if possible. The actual data is still from virtio-win, just unpacked. Changes from v1: - adapt to use the priority in libosinfo 1.7.0+ - filter out non-pre-installable drivers - collect all the drivers matching the requirements, not just the first, sorting them by priority like libosinfo does
2017 Sep 21
18
[PATCH v2 00/18] Replace many more uses of the Str module with PCRE.
v1 was here: https://www.redhat.com/archives/libguestfs/2017-September/msg00135.html This is a more complete evolution of the earlier patch. It replaces most important uses of Str with PCRE throughout the code. It also extends the bindings with some useful features like case-insensitive regexps. The main places I *didn't* touch are the generator (GObject uses Str extensively); and
2017 Sep 22
27
[PATCH v3 00/22] Replace almost all uses of the Str module with PCRE.
v1: https://www.redhat.com/archives/libguestfs/2017-September/msg00135.html v2: https://www.redhat.com/archives/libguestfs/2017-September/msg00158.html v3 is almost identical to v2, but I have added 4 extra commits to almost finish the job of replacing Str everywhere possible (note it's not possible to replace Str in common/mlstdutils or the generator because those are pure OCaml). As
2017 Aug 01
7
[PATCH 0/2] Add lightweight bindings for PCRE.
We'd like to use PCRE instead of the awful Str module. However I don't necessarily want to pull in the extra dependency of ocaml-pcre, and in any case ocaml-pcre is rather difficult to use. This introduces very simplified and lightweight bindings for PCRE. They work rather like Str in that there is some global state (actually thread-local in this implementation) between the matching and
2017 Aug 01
6
[PATCH v2 0/3] common: Add a lightweight OCaml binding for PCRE.
v2: - Change the OCaml code in the daemon to use PCRE instead of Str. - Call pcre_compile2 so we can capture the error code on failure. - Extend the test suite. - Some other cleanups, but very minor. Rich.