1
0
mirror of https://github.com/cc65/cc65.git synced 2024-07-01 23:29:41 +00:00

Improved an error message in case of invalid input data

git-svn-id: svn://svn.cc65.org/cc65/trunk@2626 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
cuz 2003-11-09 12:12:02 +00:00
parent 18fb938f48
commit 814a0d3c84

View File

@ -7,7 +7,7 @@
/* */ /* */
/* */ /* */
/* (C) 1998-2003 Ullrich von Bassewitz */ /* (C) 1998-2003 Ullrich von Bassewitz */
/* Römerstrasse 52 */ /* Römerstraße 52 */
/* D-70794 Filderstadt */ /* D-70794 Filderstadt */
/* EMail: uz@cc65.org */ /* EMail: uz@cc65.org */
/* */ /* */
@ -191,7 +191,10 @@ const char* GetSourceFileName (const ObjData* O, unsigned Index)
} else { } else {
/* Check the parameter */ /* Check the parameter */
PRECONDITION (Index < O->FileCount); if (Index >= O->FileCount) {
Error ("Invalid file index (%u) in module `%s' (input file corrupt?)",
Index, GetObjFileName (O));
}
/* Return the name */ /* Return the name */
return GetString (O->Files[Index]->Name); return GetString (O->Files[Index]->Name);