diff options
author | Stephane Carrez <stcarrez@nerim.fr> | 2001-07-18 20:59:00 +0000 |
---|---|---|
committer | Stephane Carrez <stcarrez@nerim.fr> | 2001-07-18 20:59:00 +0000 |
commit | c774cec6a71cec1932152c9838d0a7142409d8ce (patch) | |
tree | 41815fe32cc666c19a0c2fdbe32713c99d02994b /gdb/tui/tuiSourceWin.c | |
parent | 227288a05cfbdfb8a562a19c1a59a68e1d91af48 (diff) | |
download | gdb-c774cec6a71cec1932152c9838d0a7142409d8ce.zip gdb-c774cec6a71cec1932152c9838d0a7142409d8ce.tar.gz gdb-c774cec6a71cec1932152c9838d0a7142409d8ce.tar.bz2 |
* tuiData.h (TuiLocatorElement): Use CORE_ADDR for address member.
(TuiLineOrAddress): Likewise.
* tuiDisassem.c (tuiGetBeginAsmAddress): Use CORE_ADDR to specify
an address.
(tuiSetDisassemContent): Likewise.
(tuiShowDisassem, tuiShowDisassemAndUpdateSource): Likewise.
* tuiLayout.c (_extractDisplayStartAddr): Likewise.
(tuiSetLayout): Likewise.
* tuiSourceWin.c (tuiDisplayMainFunction): Likewise.
(tuiUpdateSourceWindowsWithAddr): Likewise.
(tuiUpdateSourceWindowsWithLine): Likewise.
(tuiSetHasBreakAt): Likewise.
* tuiStack.c (tuiSetLocatorInfo): Likewise.
(tuiSwitchFilename): Likewise.
(tuiUpdateLocatorInfoFromFrame): Likewise.
(tuiSetLocatorContent): Likewise.
(tuiShowFrameInfo): Likewise.
* tuiDisassem.h: Update prototypes to use CORE_ADDR.
* tuiSourceWin.h: Likewise.
* tuiStack.h: Likewise.
Diffstat (limited to 'gdb/tui/tuiSourceWin.c')
-rw-r--r-- | gdb/tui/tuiSourceWin.c | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/gdb/tui/tuiSourceWin.c b/gdb/tui/tuiSourceWin.c index 4bfc04e..8edb60b 100644 --- a/gdb/tui/tuiSourceWin.c +++ b/gdb/tui/tuiSourceWin.c @@ -28,6 +28,8 @@ #include "tui.h" #include "tuiData.h" #include "tuiStack.h" +#include "tuiWin.h" +#include "tuiGeneralWin.h" #include "tuiSourceWin.h" #include "tuiSource.h" #include "tuiDisassem.h" @@ -93,13 +95,13 @@ tuiDisplayMainFunction (void) CORE_ADDR addr; addr = parse_and_eval_address ("main"); - if (addr <= (CORE_ADDR) 0) + if (addr == (CORE_ADDR) 0) addr = parse_and_eval_address ("MAIN"); - if (addr > (CORE_ADDR) 0) + if (addr != (CORE_ADDR) 0) { struct symtab_and_line sal; - tuiUpdateSourceWindowsWithAddr ((Opaque) addr); + tuiUpdateSourceWindowsWithAddr (addr); sal = find_pc_line (addr, 0); tuiSwitchFilename (sal.symtab->filename); } @@ -178,9 +180,9 @@ tuiUpdateSourceWindowAsIs (TuiWinInfoPtr winInfo, struct symtab *s, ** reflect the input address. */ void -tuiUpdateSourceWindowsWithAddr (Opaque addr) +tuiUpdateSourceWindowsWithAddr (CORE_ADDR addr) { - if (addr > (Opaque) NULL) + if (addr != 0) { struct symtab_and_line sal; @@ -194,10 +196,8 @@ tuiUpdateSourceWindowsWithAddr (Opaque addr) tuiShowDisassemAndUpdateSource (addr); break; default: - sal = find_pc_line ((CORE_ADDR) addr, 0); - tuiShowSource (sal.symtab, - (Opaque) sal.line, - FALSE); + sal = find_pc_line (addr, 0); + tuiShowSource (sal.symtab, sal.line, FALSE); break; } } @@ -248,14 +248,14 @@ tuiUpdateSourceWindowsWithLine (struct symtab *s, int line) case DISASSEM_COMMAND: case DISASSEM_DATA_COMMAND: find_line_pc (s, line, &pc); - tuiUpdateSourceWindowsWithAddr ((Opaque) pc); + tuiUpdateSourceWindowsWithAddr (pc); break; default: - tuiShowSource (s, (Opaque) line, FALSE); + tuiShowSource (s, line, FALSE); if (currentLayout () == SRC_DISASSEM_COMMAND) { find_line_pc (s, line, &pc); - tuiShowDisassem ((Opaque) pc); + tuiShowDisassem (pc); } break; } @@ -527,7 +527,7 @@ tuiSetHasBreakAt (struct breakpoint *bp, TuiWinInfoPtr winInfo, int hasBreak) } else gotIt = (content[i]->whichElement.source.lineOrAddr.addr - == (Opaque) bp->address); + == bp->address); if (gotIt) { content[i]->whichElement.source.hasBreak = hasBreak; |