mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2025-01-31 04:20:34 +00:00
- fixed: FResourceLump::LumpNameSetup passed negative numbers to FString::Truncate for extension-less lump names.
This commit is contained in:
parent
ffea457d81
commit
32e0123e1b
1 changed files with 2 additions and 1 deletions
|
@ -95,7 +95,8 @@ void FResourceLump::LumpNameSetup(FString iname)
|
||||||
{
|
{
|
||||||
long slash = iname.LastIndexOf('/');
|
long slash = iname.LastIndexOf('/');
|
||||||
FString base = (slash >= 0) ? iname.Mid(slash + 1) : iname;
|
FString base = (slash >= 0) ? iname.Mid(slash + 1) : iname;
|
||||||
base.Truncate(base.LastIndexOf('.'));
|
auto dot = base.LastIndexOf('.');
|
||||||
|
if (dot >= 0) base.Truncate(dot);
|
||||||
uppercopy(Name, base);
|
uppercopy(Name, base);
|
||||||
Name[8] = 0;
|
Name[8] = 0;
|
||||||
FullName = iname;
|
FullName = iname;
|
||||||
|
|
Loading…
Reference in a new issue