Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(28)

Issue 10440066: Fix skipping first library for NaCl glibc programs. (Closed)

Created:
8 years, 6 months ago by halyavin
Modified:
8 years, 6 months ago
Reviewers:
eaeltsin
CC:
native-client-reviews_googlegroups.com
Base URL:
http://git.chromium.org/native_client/nacl-gdb.git@nacl-stub
Visibility:
Public.

Description

Fix skipping first library for NaCl glibc programs. NaCl glibc programs are started as dynamic linker with command line parameters. So exec_bfd points out to the dynamic linker which has a .dynamic section. This leads to ignore_first = 1 and skipping main program in dynamic library list. By using interpreter check instead we weaken the condition to include the NaCl case. This adds to ignore_first = 0 branch all cases where main program doesn't have an interpreter but has a .dynamic section i.e. launched program is a dynamic linker or statically linked program that somehow loaded dynamic linker later. In first case main (not a linker) program is first in the list. In the second case statically linked program is not present in the list. In Linux this adds main program to the list of shared libraries too if it is launched via dynamic linker. But gdb can't load symbols for it since main program has an empty name in the list. BUG= http://code.google.com/p/nativeclient/issues/detail?id=2774 TEST= none R=eaeltsin@google.com Committed: https://git.chromium.org/gitweb?p=native_client/nacl-gdb.git;a=commit;h=38b6780

Patch Set 1 #

Patch Set 2 : update commit message #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1 line, -1 line) Patch
M gdb/solib-svr4.c View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 3 (0 generated)
halyavin
8 years, 6 months ago (2012-05-31 10:12:42 UTC) #1
halyavin
I updated description.
8 years, 6 months ago (2012-05-31 10:35:38 UTC) #2
eaeltsin
8 years, 6 months ago (2012-05-31 12:19:31 UTC) #3
lgtm

Powered by Google App Engine
This is Rietveld 408576698