public inbox for frysk-cvs@sourceware.org help / color / mirror / Atom feed
From: moore@sourceware.org To: frysk-cvs@sourceware.org Subject: [SCM] master: reformat FunctionBreakpoint.java in Java style Date: Fri, 11 Jan 2008 16:19:00 -0000 [thread overview] Message-ID: <20080111161905.3362.qmail@sourceware.org> (raw) The branch, master has been updated via 9feb25bcf5110af8f27e0125b6fa1bcc3fd10577 (commit) via 21baef673791bd2bec2ee4308e8e377898f57ebe (commit) from dae63f3724c8a8eb9a5d92d0aa9df4bbd809ac3e (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email. - Log ----------------------------------------------------------------- commit 9feb25bcf5110af8f27e0125b6fa1bcc3fd10577 Author: Tim Moore <moore@blackbox.bricoworks.com> Date: Fri Jan 11 16:11:12 2008 +0100 reformat FunctionBreakpoint.java in Java style commit 21baef673791bd2bec2ee4308e8e377898f57ebe Author: Tim Moore <moore@blackbox.bricoworks.com> Date: Thu Jan 10 17:47:03 2008 +0100 Protect against null addresses from raw symbol table lookup frysk-core/frysk/rt/ChangeLog: 2008-01-11 Tim Moore <timoore@redhat.com> * FunctionBreakpoint.java (getBreakpointRawAddresses): Filter out any naughty null addresses. ----------------------------------------------------------------------- Summary of changes: frysk-core/frysk/rt/ChangeLog | 5 ++ frysk-core/frysk/rt/FunctionBreakpoint.java | 69 +++++++++++++-------------- 2 files changed, 39 insertions(+), 35 deletions(-) First 500 lines of diff: diff --git a/frysk-core/frysk/rt/ChangeLog b/frysk-core/frysk/rt/ChangeLog index 4f74228..dd2942c 100644 --- a/frysk-core/frysk/rt/ChangeLog +++ b/frysk-core/frysk/rt/ChangeLog @@ -1,3 +1,8 @@ +2008-01-11 Tim Moore <timoore@redhat.com> + + * FunctionBreakpoint.java (getBreakpointRawAddresses): Filter out + any naughty null addresses. + 2008-01-07 Andrew Cagney <cagney@redhat.com> * Breakpoint.java: Update; use Task.getPC(). diff --git a/frysk-core/frysk/rt/FunctionBreakpoint.java b/frysk-core/frysk/rt/FunctionBreakpoint.java index 073d974..4f1355b 100644 --- a/frysk-core/frysk/rt/FunctionBreakpoint.java +++ b/frysk-core/frysk/rt/FunctionBreakpoint.java @@ -51,21 +51,19 @@ import frysk.proc.Task; import frysk.symtab.SymbolFactory; public class FunctionBreakpoint - extends SourceBreakpoint -{ - private String name; - private boolean containsInlineInstances = false; - private DwarfDie die; + extends SourceBreakpoint { + private String name; + private boolean containsInlineInstances = false; + private DwarfDie die; - /** - * Set a breakpoint based on a DwarfDie or just a name. - */ - public FunctionBreakpoint(int id, String name, DwarfDie die) - { - super(id); - this.name = name; - this.die = die; - } + /** + * Set a breakpoint based on a DwarfDie or just a name. + */ + public FunctionBreakpoint(int id, String name, DwarfDie die) { + super(id); + this.name = name; + this.die = die; + } public LinkedList getBreakpointRawAddresses(Task task) { if (die != null) { @@ -90,31 +88,32 @@ public class FunctionBreakpoint return addrs; } else { - return SymbolFactory.getSymbol(task, name); + // Filter any null values that have sneaked in. + LinkedList addrs = SymbolFactory.getSymbol(task, name); + Long nullVal = new Long(0); + while (addrs.remove(nullVal)) { + } + return addrs; } } - public long getRawAddress(Object addr) - { - return ((Long)addr).longValue(); - } + public long getRawAddress(Object addr) { + return ((Long)addr).longValue(); + } - public String getName() - { - return name; - } + public String getName() { + return name; + } - public boolean containsInlineInstances() - { - // XXX What about in different processes? - return containsInlineInstances; - } + public boolean containsInlineInstances() { + // XXX What about in different processes? + return containsInlineInstances; + } - public PrintWriter output(PrintWriter writer) - { - writer.print(getName()); - if (containsInlineInstances()) - writer.print("*"); - return writer; - } + public PrintWriter output(PrintWriter writer) { + writer.print(getName()); + if (containsInlineInstances()) + writer.print("*"); + return writer; + } } hooks/post-receive -- frysk system monitor/debugger
reply other threads:[~2008-01-11 16:19 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20080111161905.3362.qmail@sourceware.org \ --to=moore@sourceware.org \ --cc=frysk-cvs@sourceware.org \ --cc=frysk@sourceware.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).