From d48ebab82ed530df534309006f62e3edf1322ee6 Mon Sep 17 00:00:00 2001 From: mysticbbs Date: Fri, 20 Sep 2013 10:21:19 -0400 Subject: [PATCH] changes --- mdl/m_fileio.pas | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/mdl/m_fileio.pas b/mdl/m_fileio.pas index b2b556a..473b574 100644 --- a/mdl/m_fileio.pas +++ b/mdl/m_fileio.pas @@ -397,12 +397,13 @@ Function JustFileName (Str: String) : String; Var Temp : Byte; Begin - Temp := Pos ('.', Str); - - If Temp > 0 Then - Delete (Str, Temp, Ord(Str[0])); - Result := Str; + + For Temp := Length(Result) DownTo 1 Do + If Result[Temp] = '.' Then Begin + Delete (Result, Temp, 255); + Break; + End; End; Function JustFileExt (Str: String) : String;