Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* fix use of reserved name index.
- Loading branch information
Showing
2 changed files
with
53 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
From f3c73966a3089e96e14f2138f72482fcd7ca3c8f Mon Sep 17 00:00:00 2001 | ||
From: Jerome Duval <jerome.duval@gmail.com> | ||
Date: Wed, 7 Dec 2016 15:35:35 +0000 | ||
Subject: index is reserved. | ||
|
||
|
||
diff --git a/src/examples/convtab_dump.c b/src/examples/convtab_dump.c | ||
index 3a55a26..e1e55a5 100644 | ||
--- a/src/examples/convtab_dump.c | ||
+++ b/src/examples/convtab_dump.c | ||
@@ -29,7 +29,7 @@ | ||
// raw table | ||
#define MAX_TAB_SIZE 64*1024*1024 | ||
uint8_t tab[MAX_TAB_SIZE]; | ||
-uint32_t index[0xffff]; | ||
+uint32_t index_table[0xffff]; | ||
|
||
static size_t _read_tab(const char *file) | ||
{ | ||
@@ -97,9 +97,9 @@ int main(int argc, char **argv) | ||
|
||
printf(" Segment %d: %d entries\n", segment, numEntries); | ||
|
||
- // read index table | ||
+ // read index_table table | ||
for (entry = 0; entry < numEntries; entry++) { | ||
- index[entry] = FETCH4(&tab[offset]); | ||
+ index_table[entry] = FETCH4(&tab[offset]); | ||
offset += 4; | ||
} | ||
|
||
@@ -125,12 +125,12 @@ int main(int argc, char **argv) | ||
memcpy(patch1, &tab[ offset ], sizeof(patch1)); | ||
offset += 5; | ||
|
||
- uint64_t off0 = (( (uint64_t)index[entry] + | ||
+ uint64_t off0 = (( (uint64_t)index_table[entry] + | ||
(uint64_t)patch0_address_adjust) * | ||
(uint64_t)0xC0 + | ||
(uint64_t)patch0_buffer_offset); | ||
|
||
- uint64_t off1 = (( (uint64_t)index[entry] + | ||
+ uint64_t off1 = (( (uint64_t)index_table[entry] + | ||
(uint64_t)patch0_address_adjust + | ||
(uint64_t)patch1_address_adjust) * | ||
(uint64_t)0xC0 + | ||
-- | ||
2.10.2 | ||
|