public inbox for frysk-cvs@sourceware.org help / color / mirror / Atom feed
From: scox@sourceware.org To: frysk-cvs@sourceware.org Subject: [SCM] master: Merge branch 'master' of ssh://sources.redhat.com/git/frysk Date: Tue, 13 Nov 2007 00:41:00 -0000 [thread overview] Message-ID: <20071113004151.10165.qmail@sourceware.org> (raw) The branch, master has been updated via 815b8c4c2b6a75432eddf73cb74df27e9553acb5 (commit) via 847686667e0bee61585272f989e62d68595b4188 (commit) from 0631ebed24c1df74fb903d8429916768602aca43 (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email. - Log ----------------------------------------------------------------- commit 815b8c4c2b6a75432eddf73cb74df27e9553acb5 Merge: 847686667e0bee61585272f989e62d68595b4188 0631ebed24c1df74fb903d8429916768602aca43 Author: Stan Cox <scox@redhat.com> Date: Mon Nov 12 19:39:55 2007 -0500 Merge branch 'master' of ssh://sources.redhat.com/git/frysk commit 847686667e0bee61585272f989e62d68595b4188 Author: Stan Cox <scox@redhat.com> Date: Mon Nov 12 19:39:16 2007 -0500 Fix line numbers and current line position. * ListCommand.java (interpret): Initialize from function PC. Right adjust line numbers. ----------------------------------------------------------------------- Summary of changes: frysk-core/frysk/hpd/ChangeLog | 5 +++++ frysk-core/frysk/hpd/ListCommand.java | 25 +++++++++++++++++++------ 2 files changed, 24 insertions(+), 6 deletions(-) First 500 lines of diff: diff --git a/frysk-core/frysk/hpd/ChangeLog b/frysk-core/frysk/hpd/ChangeLog index 5f65f6c..75453df 100644 --- a/frysk-core/frysk/hpd/ChangeLog +++ b/frysk-core/frysk/hpd/ChangeLog @@ -1,3 +1,8 @@ +2007-11-12 Stan Cox <scox@redhat.com> + + * ListCommand.java (interpret): Initialize from function PC. + Right adjust line numbers. + 2007-11-12 Andrew Cagney <cagney@redhat.com> * TestStackCommands.java (testFrame()): New. diff --git a/frysk-core/frysk/hpd/ListCommand.java b/frysk-core/frysk/hpd/ListCommand.java index 8f76a8e..c4f3cc4 100644 --- a/frysk-core/frysk/hpd/ListCommand.java +++ b/frysk-core/frysk/hpd/ListCommand.java @@ -132,7 +132,7 @@ class ListCommand extends ParameterizedCommand { line = exec_line - 10; } - if (file== null) { + if (file == null) { if (frame.getLines().length > 0) { file = (frame.getLines()[0]).getFile(); if (file == null) { @@ -141,7 +141,8 @@ class ListCommand extends ParameterizedCommand { return; } line = (frame.getLines()[0]).getLine() - 10; - exec_line = line; + if (exec_line == 0) + exec_line = line; } else { cli.outWriter.println("No source for current frame"); @@ -158,16 +159,28 @@ class ListCommand extends ParameterizedCommand { boolean display = false; int endLine = line + StrictMath.abs(windowSize); String flag = ""; - while ((str = lr.readLine()) != null) { + while ((str = lr.readLine()) != null) { if (lr.getLineNumber() == line) display = true; else if (lr.getLineNumber() == endLine) break; if (display && lr.getLineNumber() == exec_line) flag = "*"; - - if (display) { - cli.outWriter.println(lr.getLineNumber() + flag + "\t "+ str); + else + flag = " "; + + if (display) { + int lineNumber = lr.getLineNumber(); + String rightAdjust; + if (lineNumber < 10) + rightAdjust = " "; + else if (lineNumber < 100) + rightAdjust = " "; + else if (lineNumber < 1000) + rightAdjust = " "; + else + rightAdjust = ""; + cli.outWriter.println(flag + rightAdjust + lineNumber + "\t "+ str); flag = ""; } } hooks/post-receive -- frysk system monitor/debugger
next reply other threads:[~2007-11-13 0:41 UTC|newest] Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top 2007-11-13 0:41 scox [this message] -- strict thread matches above, loose matches on Subject: below -- 2008-06-05 15:33 rmoseley 2008-05-12 16:30 rmoseley 2008-05-12 16:07 pmuldoon 2008-05-09 17:29 rmoseley 2008-04-02 22:41 pmuldoon 2008-04-01 12:28 pmuldoon 2008-03-20 20:20 rmoseley 2008-03-18 16:22 pmuldoon 2008-02-26 15:32 pmuldoon 2008-01-24 19:23 rmoseley 2008-01-23 21:10 rmoseley 2008-01-03 16:55 pmuldoon 2007-12-13 20:18 rmoseley 2007-12-04 17:45 jflavio 2007-11-30 4:24 jflavio 2007-11-28 21:40 jflavio 2007-11-28 16:20 jflavio 2007-11-28 13:08 pmuldoon 2007-11-28 12:04 mark 2007-11-20 22:47 scox 2007-11-19 17:58 scox 2007-11-17 8:35 rmoseley 2007-11-16 15:59 scox 2007-11-16 14:59 pmuldoon 2007-11-14 2:38 scox 2007-11-14 2:09 jflavio 2007-11-10 14:47 jflavio 2007-11-10 0:34 scox 2007-11-09 14:59 jflavio
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=20071113004151.10165.qmail@sourceware.org \ --to=scox@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).