1
0
mirror of https://github.com/cc65/cc65.git synced 2024-12-25 17:29:50 +00:00

Two parts were not converted from using embedded strings to use of the new

string table.


git-svn-id: svn://svn.cc65.org/cc65/trunk@2258 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
cuz 2003-08-10 16:27:35 +00:00
parent 38e102d2df
commit 9a34fdb41e

View File

@ -434,7 +434,7 @@ void DumpObjSegments (FILE* F, unsigned long Offset)
/* Read the data for one segments */
unsigned long DataSize = Read32 (F);
unsigned long NextSeg = ftell (F) + DataSize;
char* Name = ReadStr (F);
const char* Name = GetString (&StrPool, ReadVar (F));
unsigned Len = strlen (Name);
unsigned long Size = Read32 (F);
unsigned Align = (1U << Read8 (F));
@ -444,10 +444,10 @@ void DumpObjSegments (FILE* F, unsigned long Offset)
/* Get the description for the type */
const char* TypeDesc;
switch (Type) {
case SEGTYPE_DEFAULT: TypeDesc = "SEGTYPE_DEFAULT"; break;
case SEGTYPE_ABS: TypeDesc = "SEGTYPE_ABS"; break;
case SEGTYPE_ZP: TypeDesc = "SEGTYPE_ZP"; break;
case SEGTYPE_FAR: TypeDesc = "SEGTYPE_FAR"; break;
case SEGTYPE_DEFAULT: TypeDesc = "SEGTYPE_DEFAULT"; break;
case SEGTYPE_ABS: TypeDesc = "SEGTYPE_ABS"; break;
case SEGTYPE_ZP: TypeDesc = "SEGTYPE_ZP"; break;
case SEGTYPE_FAR: TypeDesc = "SEGTYPE_FAR"; break;
default: TypeDesc = "SEGTYPE_UNKNOWN"; break;
}
@ -461,9 +461,6 @@ void DumpObjSegments (FILE* F, unsigned long Offset)
printf (" Type:%22s0x%02X (%s)\n", "", Type, TypeDesc);
printf (" Fragment count:%16lu\n", FragCount);
/* Free the Name */
xfree (Name);
/* Seek to the end of the segment data (start of next) */
FileSetPos (F, NextSeg);
}
@ -649,7 +646,7 @@ void DumpObjDbgSyms (FILE* F, unsigned long Offset)
/* Read the data for one symbol */
Type = Read8 (F);
ReadData (F, ConDes, GET_EXP_CONDES_COUNT (Type));
Name = GetString (&StrPool, ReadVar (F));
Name = GetString (&StrPool, ReadVar (F));
Len = strlen (Name);
if (IS_EXP_EXPR (Type)) {
SkipExpr (F);
@ -763,7 +760,7 @@ void DumpObjSegSize (FILE* F, unsigned long Offset)
/* Read the data for one segments */
unsigned long DataSize = Read32 (F);
unsigned long NextSeg = ftell (F) + DataSize;
char* Name = ReadStr (F);
const char* Name = GetString (&StrPool, ReadVar (F));
unsigned Len = strlen (Name);
unsigned long Size = Read32 (F);
@ -775,12 +772,9 @@ void DumpObjSegSize (FILE* F, unsigned long Offset)
/* Print the size for this segment */
printf (" %s:%*s%6lu\n", Name, 24-Len, "", Size);
/* Free the Name */
xfree (Name);
/* Seek to the end of the segment data (start of next) */
FileSetPos (F, NextSeg);
}
}
/* Destroy the string pool */
DestroyStrPool (&StrPool);