anchor.diff:  end;
   
   procedure TmFilePublisher.Publish(aContext, aLevel, aMessage: string; aDate: TDateTime);
  +var
  +  s: RawByteString;
  +  i : integer;
   begin
     if FFileName <> '' then
     begin
  -    if not FFileAssigned then
  +    if not Assigned(FFileStream) then
       begin
  -      Assign(FLogFile, FFileName);
         if FileExists(FFileName) then
  -        Append(FLogFile)
  +      begin
  +        (*
  +        if (FMaxFileSizeInMb > 0) and ((FileUtil.FileSize(FFileName) div 1024) > FMaxFileSizeInMb) then
  +        begin
  +          RenameFile(FFileName, FFileName + '.bak');
  +        end;
  +        *)
  +        FFileStream := TFileStream.Create(FFileName, fmOpenWrite);
  +        FFileStream.Seek(0, soFromEnd);
  +      end
         else
  -        Rewrite(FLogFile);
  -      FFileAssigned := true;
  +      begin
  +        FFileStream := TFileStream.Create(FFileName, fmCreate);
  +        FFileStream.Write(UTF8BOM[0],3);
  +      end;
       end;
  -    WriteLn(FLogFile, Self.GetFormattedString(aContext, aLevel, aMessage, aDate));
  -    Flush(FLogFile);
  +    s := UTF8Encode(Self.GetFormattedString(aContext, aLevel, aMessage, aDate) + sLineBreak);
  +    FFileStream.Write(s[1], Length(s));
     end;
   end;
   
  
positive.code:   strict private
      FCurrentLevel : TmLogMessageLevel;
      FFileName : TFileName;
      FLogFile: Text;
      FFileAssigned : boolean;
    public
      procedure AfterCreate; override;
      destructor Destroy; override;
  
negative.code: 
  uses
    {$ifdef lcl}Forms, StdCtrls, Controls,{$endif}
    sysutils, Classes,
    mLog;
  
  const
  