search for: copy_type_len

Displaying 6 results from an estimated 6 matches for "copy_type_len".

2011 Oct 19
1
[hivex][PATCH 2/8] generator: Add new return type to ABI: RLenValue
...uot; | RLenTypeVal -> pr "hive_type * string" | RInt32 -> pr "int32" | RInt64 -> pr "int64" @@ -1685,6 +1693,7 @@ static hive_type HiveType_val (value); static value Val_hive_type (hive_type); static value copy_int_array (size_t *); static value copy_type_len (size_t, hive_type); +static value copy_len_value (size_t, hive_value_h); static value copy_type_value (const char *, size_t, hive_type); static void raise_error (const char *) Noreturn; static void raise_closed (const char *) Noreturn; @@ -1707,6 +1716,7 @@ static void raise_closed (const char...
2011 Dec 08
0
[hivex] [PATCH 2/8] generator: Add new return type to ABI: RLenValue
...uot; | RLenTypeVal -> pr "hive_type * string" | RInt32 -> pr "int32" | RInt64 -> pr "int64" @@ -1685,6 +1693,7 @@ static hive_type HiveType_val (value); static value Val_hive_type (hive_type); static value copy_int_array (size_t *); static value copy_type_len (size_t, hive_type); +static value copy_len_value (size_t, hive_value_h); static value copy_type_value (const char *, size_t, hive_type); static void raise_error (const char *) Noreturn; static void raise_closed (const char *) Noreturn; @@ -1707,6 +1716,7 @@ static void raise_closed (const char...
2011 Aug 31
1
[hivex] OCaml binding error?
...actually corrects a problem? --Alex --- generator/generator.ml | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/generator/generator.ml b/generator/generator.ml index de103ed..c98e625 100755 --- a/generator/generator.ml +++ b/generator/generator.ml @@ -1946,7 +1946,7 @@ copy_type_len (size_t len, hive_type t) v = Val_hive_type (t); Store_field (rv, 0, v); v = Val_int (len); - Store_field (rv, 1, len); + Store_field (rv, 1, v); CAMLreturn (rv); } -- 1.7.4.4
2011 Aug 31
1
[PATCH] hivex: Add byte runs for nodes and values
...| RNodeNotFound -> pr " if (r == 0)\n"; @@ -1829,6 +1898,8 @@ static void raise_closed (const char *) Noreturn; pr " for (int i = 0; r[i] != NULL; ++i) free (r[i]);\n"; pr " free (r);\n" | RLenType -> pr " rv = copy_type_len (len, t);\n" + | RLenNode -> pr " rv = copy_len (len);\n" + | RLenValue -> pr " rv = copy_len (len);\n" | RLenTypeVal -> pr " rv = copy_type_value (r, len, t);\n"; pr " free (r);\n" @@ -1951,6 +202...
2014 Aug 04
6
[hivex] Segfault for an integer value to node_set_value
Hi, When an integer argument is passed as value, node_set_value segfaults. Reproducer is at the end of this message The backtrace points at hivex-py.c, function get_value. While obj is non-NULL, `bytes = PyUnicode_AsUTF8String (obj);` returns NULL. Kind regards, Peter https://lekensteyn.nl #!/usr/bin/env python3 import hivex, sys h = hivex.Hivex(sys.argv[1]) print(h) val = {
2014 Aug 16
7
[hivex] [PATCH 0/6] Python fixes for node_set_value
Hi, This patch series is based on a prior patch[1], splitting off changes as requested and incorporating feedback from Richard Jones. It introduces type validation to avoid segmentation faults (instead, it reports an exception) and fixes handling of the bytes type in Python 3. Major changes since that series: - Drop newly introduced support for integer types for DWORD/QWORDS - Reject Unicode