turbopower: md5sumoffile: fixed utf8 filename

git-svn-id: trunk@38616 -
This commit is contained in:
mattias 2012-09-11 12:42:21 +00:00
parent 3ba660c99f
commit fb69f5184b

View File

@ -41,7 +41,7 @@ uses
GraphType, GraphType,
LCLIntf, LCLIntf,
LMessages, LMessages,
FileUtil, FileUtil, lazutf8classes,
LCLProc, LCLProc,
{$ELSE} {$ELSE}
Messages, Messages,
@ -789,9 +789,9 @@ end;
{ Calculates the MD5 Digest of a file } { Calculates the MD5 Digest of a file }
function MD5SumOfFile(const FileName : string) : string; function MD5SumOfFile(const FileName : string) : string;
var var
FileSt : TFileStream; FileSt : TFileStreamUTF8;
begin begin
FileSt := TFileStream.Create(UTF8ToSys(FileName), CrcFileMode); FileSt := TFileStreamUTF8.Create(FileName, CrcFileMode);
try try
Result := MD5SumOfStream(FileSt); Result := MD5SumOfStream(FileSt);
finally finally