Created
May 13, 2013 08:20
-
-
Save MrVan/5566887 to your computer and use it in GitHub Desktop.
resolve the layout problem and rela problem
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
From c680d5c27792cb7ca5460542b6b3dd08de38fe9b Mon Sep 17 00:00:00 2001 | |
From: Peng Fan <van.freenix@gmail.com> | |
Date: Mon, 13 May 2013 16:16:05 +0800 | |
Subject: [PATCH 5/5] modify-rela-related-problem and layout problem | |
--- | |
rld-rap.cpp | 15 +++++++++++++-- | |
1 file changed, 13 insertions(+), 2 deletions(-) | |
diff --git a/rld-rap.cpp b/rld-rap.cpp | |
index 2f04bdd..8c2006d 100644 | |
--- a/rld-rap.cpp | |
+++ b/rld-rap.cpp | |
@@ -882,10 +882,21 @@ namespace rld | |
obj.secs[s].set_offset (pobj.secs[s]); | |
sec_size[s] = obj.secs[s].offset + obj.secs[s].size (); | |
sec_align[s] = obj.secs[s].alignment (); | |
- sec_rela[s] = obj.secs[s].rela; | |
+ if (obj.secs[s].rela == true) | |
+ sec_rela[s] = obj.secs[s].rela; | |
+ else ; | |
} | |
++poi; | |
- } | |
+ } else { | |
+ /* objs.begin() */ | |
+ for (int s = 0; s < rap_secs; ++s) { | |
+ sec_size[s] = obj.secs[s].size (); | |
+ sec_align[s] = obj.secs[s].alignment (); | |
+ if (obj.secs[s].rela == true) | |
+ sec_rela[s] = true; | |
+ else ; | |
+ } | |
+ } | |
collect_symbols (obj); | |
-- | |
1.7.10.4 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment