Displaying 10 results from an estimated 10 matches for "_hivex_windows_utf16_to_utf8".
2013 Nov 22
0
[PATCH 3/3] Correctly handle latin1-encoded key/value names
...ternal.h b/lib/hivex-internal.h
index d7ce339..4135f58 100644
--- a/lib/hivex-internal.h
+++ b/lib/hivex-internal.h
@@ -268,7 +268,11 @@ extern size_t * _hivex_return_offset_list (offset_list *list);
extern void _hivex_print_offset_list (offset_list *list, FILE *fp);
/* utf16.c */
-extern char *_hivex_windows_utf16_to_utf8 (/* const */ char *input, size_t len);
+extern char* _hivex_to_utf8 (/* const */ char *input, size_t len, char* input_encoding);
+#define _hivex_windows_utf16_to_utf8(_input, _len) \
+ _hivex_to_utf8 (_input, _len, "UTF-16LE")
+#define _hivex_windows_latin1_to_utf8(_input, _len) \
+ _hi...
2013 Nov 22
4
[PATCH 1/3] Document ntreg_nk_record.flags
---
lib/hivex-internal.h | 14 +++++++++++++-
1 file changed, 13 insertions(+), 1 deletion(-)
diff --git a/lib/hivex-internal.h b/lib/hivex-internal.h
index f391b98..d7ce339 100644
--- a/lib/hivex-internal.h
+++ b/lib/hivex-internal.h
@@ -125,7 +125,19 @@ struct ntreg_hbin_block {
struct ntreg_nk_record {
int32_t seg_len; /* length (always -ve because used) */
char id[2];
2018 Feb 09
3
[PATCH] Add a cache for iconv_t handles to hive_t
...+ for (int t=0; t<3; t++) {
+ pthread_mutex_init (&h->iconv_cache[t].mutex, NULL);
+ h->iconv_cache[t].handle = NULL;
+ }
+
/* Last modified time. */
h->last_modified = le64toh ((int64_t) h->hdr->last_modified);
if (h->msglvl >= 2) {
- char *name = _hivex_windows_utf16_to_utf8 (h->hdr->name, 64);
+ char *name = _hivex_recode (h, utf16le_to_utf8,
+ h->hdr->name, 64, NULL);
fprintf (stderr,
"hivex_open: header fields:\n"
@@ -424,6 +459,12 @@ hivex_close (hive_h *h)
else
r = 0;
free (h-&...
2018 Feb 09
0
Re: [PATCH] Add a cache for iconv_t handles to hive_t
...hread_mutex_init (&h->iconv_cache[t].mutex, NULL);
> + h->iconv_cache[t].handle = NULL;
> + }
> +
> /* Last modified time. */
> h->last_modified = le64toh ((int64_t) h->hdr->last_modified);
>
> if (h->msglvl >= 2) {
> - char *name = _hivex_windows_utf16_to_utf8 (h->hdr->name, 64);
> + char *name = _hivex_recode (h, utf16le_to_utf8,
> + h->hdr->name, 64, NULL);
>
> fprintf (stderr,
> "hivex_open: header fields:\n"
> @@ -424,6 +459,12 @@ hivex_close (hive_h *h)
&g...
2018 Feb 09
2
[PATCH] Add a cache for iconv_t handles to hive_t
...}
+ for (int t=0; t<3; t++) {
+ glthread_lock_init (&h->iconv_cache[t].mutex);
+ h->iconv_cache[t].handle = NULL;
+ }
+
/* Last modified time. */
h->last_modified = le64toh ((int64_t) h->hdr->last_modified);
if (h->msglvl >= 2) {
- char *name = _hivex_windows_utf16_to_utf8 (h->hdr->name, 64);
+ char *name = _hivex_recode (h, utf16le_to_utf8,
+ h->hdr->name, 64, NULL);
fprintf (stderr,
"hivex_open: header fields:\n"
@@ -424,6 +458,12 @@ hivex_close (hive_h *h)
else
r = 0;
free (h-&...
2013 Dec 31
0
[PATCH 2/2] lib: utf16: Fix const-correctness issues in _hivex_recode function.
...t input_len,
- char *output_encoding, size_t *output_len);
+extern char * _hivex_recode (const char *input_encoding,
+ const char *input, size_t input_len,
+ const char *output_encoding, size_t *output_len);
#define _hivex_windows_utf16_to_utf8(_input, _len) \
_hivex_recode ("UTF-16LE", _input, _len, "UTF-8", NULL)
#define _hivex_windows_latin1_to_utf8(_input, _len) \
diff --git a/lib/utf16.c b/lib/utf16.c
index 437613b..3641580 100644
--- a/lib/utf16.c
+++ b/lib/utf16.c
@@ -30,8 +30,8 @@
#include "hivex-inte...
2013 Dec 31
2
[PATCH 1/2] lib: write: Remove unused variable.
---
lib/write.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/lib/write.c b/lib/write.c
index 8c4dd8e..384c6b2 100644
--- a/lib/write.c
+++ b/lib/write.c
@@ -954,7 +954,6 @@ hivex_node_set_values (hive_h *h, hive_node_h node,
for (i = 0; i < nr_values; ++i) {
/* Allocate vk record to store this (key, value) pair. */
static const char vk_id[2] = { 'v', 'k' };
-
2013 Nov 24
4
[PATCH 1/3] lib: Further generalize iconv wrapper function.
...utf16.c */
-extern char* _hivex_to_utf8 (/* const */ char *input, size_t len, char* input_encoding);
+extern char* _hivex_recode (char *input_encoding,
+ const char *input, size_t input_len,
+ char *output_encoding, size_t *output_len);
#define _hivex_windows_utf16_to_utf8(_input, _len) \
- _hivex_to_utf8 (_input, _len, "UTF-16LE")
+ _hivex_recode ("UTF-16LE", _input, _len, "UTF-8", NULL)
#define _hivex_windows_latin1_to_utf8(_input, _len) \
- _hivex_to_utf8 (_input, _len, "LATIN1")
+ _hivex_recode ("LATIN1", _in...
2013 Oct 16
1
[Hivex] [PATCH] lib: Promote byte_conversions.h #include to hivex-internal.h
...rsions.h"
hive_node_h
hivex_root (hive_h *h)
diff --git a/lib/utf16.c b/lib/utf16.c
index d0f2e45..844715c 100644
--- a/lib/utf16.c
+++ b/lib/utf16.c
@@ -27,7 +27,6 @@
#include "hivex.h"
#include "hivex-internal.h"
-#include "byte_conversions.h"
char *
_hivex_windows_utf16_to_utf8 (/* const */ char *input, size_t len)
diff --git a/lib/value.c b/lib/value.c
index d713cdc..6d0f266 100644
--- a/lib/value.c
+++ b/lib/value.c
@@ -32,7 +32,6 @@
#include "hivex.h"
#include "hivex-internal.h"
-#include "byte_conversions.h"
int
_hivex_get_values...
2013 Jul 25
19
[PATCH hivex 00/19] Fix read/write handling of li-records.
This is, hopefully, a full fix for handling of li-records.
See:
https://bugzilla.redhat.com/show_bug.cgi?id=717583
https://bugzilla.redhat.com/show_bug.cgi?id=987463
Rich.