diff --git a/fcl/inc/zipper.pp b/fcl/inc/zipper.pp index 801de5a010..32a48e9e5e 100644 --- a/fcl/inc/zipper.pp +++ b/fcl/inc/zipper.pp @@ -1313,10 +1313,14 @@ Var Count : Longint; CRC : LongWord; ZMethod : Word; + OutputFileName : string; Begin Try ReadZipHeader(Item,CRC,ZMethod); - OpenOutput(FOutputPath+Item.Name); + OutputFileName:=Item.Name; + if FOutputPath<>'' then + OutputFileName:=IncludeTrailingPathDelimiter(FOutputPath)+OutputFileName; + OpenOutput(OutputFileName); if ZMethod=0 then begin Count:=FOutFile.CopyFrom(FZipFile,LocalHdr.Compressed_Size);