summaryrefslogtreecommitdiff
path: root/src/format/dex
diff options
context:
space:
mode:
authorCyrille Bagard <nocbos@gmail.com>2015-09-11 20:40:24 (GMT)
committerCyrille Bagard <nocbos@gmail.com>2015-09-11 20:40:24 (GMT)
commit18648e4e8763a3bc005d6fae51eae3d1528d7d29 (patch)
tree05feca5b6c5575b2a048b60130e3207b9f2c355a /src/format/dex
parent9f8c79e3b272960b48bfd85a24f4b5cb5651df2d (diff)
Created an interface from the original GBinContent object.
git-svn-id: svn://svn.gna.org/svn/chrysalide/trunk@576 abbe820e-26c8-41b2-8c08-b7b2b41f8b0a
Diffstat (limited to 'src/format/dex')
-rw-r--r--src/format/dex/dex-int.c4
-rwxr-xr-xsrc/format/dex/dex.c2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/format/dex/dex-int.c b/src/format/dex/dex-int.c
index 914f491..5ce0675 100644
--- a/src/format/dex/dex-int.c
+++ b/src/format/dex/dex-int.c
@@ -64,12 +64,12 @@ bool read_dex_header(const GDexFormat *format, off_t *pos, dex_header *header)
length = 0; //G_BIN_FORMAT(format)->length;
for (i = 0; i < DEX_FILE_MAGIC_LEN && result; i++)
- result = read_u8(&header->magic[i], content, pos, length, SRE_LITTLE);
+ result = read_u8(&header->magic[i], content, pos, length);
result &= read_u32(&header->checksum, content, pos, length, SRE_LITTLE);
for (i = 0; i < 20 && result; i++)
- result = read_u8(&header->signature[i], content, pos, length, SRE_LITTLE);
+ result = read_u8(&header->signature[i], content, pos, length);
result &= read_u32(&header->file_size, content, pos, length, SRE_LITTLE);
result &= read_u32(&header->header_size, content, pos, length, SRE_LITTLE);
diff --git a/src/format/dex/dex.c b/src/format/dex/dex.c
index eb78f79..0015357 100755
--- a/src/format/dex/dex.c
+++ b/src/format/dex/dex.c
@@ -85,7 +85,7 @@ bool dex_is_matching(GBinContent *content)
init_vmpa(&addr, 0, VMPA_NO_VIRTUAL);
- result = g_binary_content_get_raw(content, &addr, DEX_FILE_MAGIC_LEN, (bin_t *)magic);
+ result = g_binary_content_read_raw(content, &addr, DEX_FILE_MAGIC_LEN, (bin_t *)magic);
result &= (memcmp(magic, DEX_FILE_MAGIC, DEX_FILE_MAGIC_LEN) == 0);