Commit 52b80488 by Pascal Obry Committed by Geert Bosch

gnatmem.adb (Read_Next): fix Curs2 value to properly handle quiet mode case for ALLOC case.

	* gnatmem.adb (Read_Next): fix Curs2 value to properly handle quiet
        mode case for ALLOC case.

	* gnatmem.adb (Read_Next): correctly fix parsing in Quiet mode on
        all platforms. Improvement of last change.

From-SVN: r46506
parent 316ad9c5
2001-10-25 Pascal Obry <obry@gnat.com>
* gnatmem.adb (Read_Next): fix Curs2 value to properly handle quiet
mode case for ALLOC case.
* gnatmem.adb (Read_Next): correctly fix parsing in Quiet mode on
all platforms. Improvement of last change.
2001-10-25 Robert Dewar <dewar@gnat.com> 2001-10-25 Robert Dewar <dewar@gnat.com>
* exp_ch4.adb (Expand_N_Allocator): Minor reformatting. * exp_ch4.adb (Expand_N_Allocator): Minor reformatting.
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
-- -- -- --
-- B o d y -- -- B o d y --
-- -- -- --
-- $Revision: 1.24 $ -- $Revision$
-- -- -- --
-- Copyright (C) 1997-2001, Ada Core Technologies, Inc. -- -- Copyright (C) 1997-2001, Ada Core Technologies, Inc. --
-- -- -- --
...@@ -191,7 +191,6 @@ procedure Gnatmem is ...@@ -191,7 +191,6 @@ procedure Gnatmem is
Target_Protocol_Len : Integer; Target_Protocol_Len : Integer;
Cross_Case : Boolean := False; Cross_Case : Boolean := False;
Tmp_Size : Storage_Count := 0; Tmp_Size : Storage_Count := 0;
Tmp_Address : Integer_Address; Tmp_Address : Integer_Address;
Tmp_Alloc : Allocation; Tmp_Alloc : Allocation;
...@@ -291,7 +290,6 @@ procedure Gnatmem is ...@@ -291,7 +290,6 @@ procedure Gnatmem is
end if; end if;
end; end;
if Cross_Case then if Cross_Case then
Put (FD, "target "); Put (FD, "target ");
Put (FD, Target_Protocol (1 .. Target_Protocol_Len)); Put (FD, Target_Protocol (1 .. Target_Protocol_Len));
...@@ -693,14 +691,14 @@ procedure Gnatmem is ...@@ -693,14 +691,14 @@ procedure Gnatmem is
return Eof; return Eof;
elsif Line (1 .. 5) = "ALLOC" then elsif Line (1 .. 5) = "ALLOC" then
-- ALLOC ^ <size> ^0x <addr> ^
-- Read the size -- Read the size
if Quiet_Mode then Curs1 := 7;
Curs2 := 5; Curs2 := Next_Separator - 1;
else
Curs1 := 7; if not Quiet_Mode then
Curs2 := Next_Separator - 1;
Tmp_Size := Storage_Count'Value (Line (Curs1 .. Curs2)); Tmp_Size := Storage_Count'Value (Line (Curs1 .. Curs2));
end if; end if;
...@@ -713,6 +711,7 @@ procedure Gnatmem is ...@@ -713,6 +711,7 @@ procedure Gnatmem is
return Alloc; return Alloc;
elsif Line (1 .. 5) = "DEALL" then elsif Line (1 .. 5) = "DEALL" then
-- DEALL ^ 0x <addr> ^
-- Read the address, skip "^0x" -- Read the address, skip "^0x"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment