summaryrefslogtreecommitdiff
path: root/addr2line.c
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-03-25 18:44:32 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-03-25 18:44:32 +0000
commit0fe34c4c3b3634cc5c8b22642e2baa2617e14cf8 (patch)
tree8fd3a1bd9900b6e8a3bdc7639f3639419a02ff6d /addr2line.c
parent925a1e1d7070584911980fdbc389ffe65757772e (diff)
main is not a pubic function, use _start instead
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45412 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'addr2line.c')
-rw-r--r--addr2line.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/addr2line.c b/addr2line.c
index 94adf85b91..cda6744e4f 100644
--- a/addr2line.c
+++ b/addr2line.c
@@ -623,9 +623,9 @@ rb_dump_backtrace_with_lines(int num_traces, void **traces, char **syms)
intptr_t main_fbase;
char *main_path;
{
- extern int main(int argc, char **argv); /* a function in the main executalbe */
+ extern void _start(void); /* a function in the main executalbe */
Dl_info info;
- dladdr(main, &info);
+ dladdr(_start, &info);
main_fbase = (intptr_t)info.dli_fbase;
}
{