From 9d2926b3f72d18f4df99d1de377be226eaa93eb5 Mon Sep 17 00:00:00 2001 From: darius Date: Sat, 1 Nov 2008 18:10:22 +0000 Subject: [PATCH] fixed AV when parsing empty messages in SVN log xml added asking for confirmation on empty message r17175 initialized author to '(no author)' (used in anonymous repositories) fixed commit messages (writing them to a temp file and using --file switch) fixed some AVs in parsing SVN log XML fixed saving of checked status in SVNSettingsForm git-svn-id: trunk@17176 - --- components/lazsvnpkg/svnlogform.pas | 5 +++-- components/lazsvnpkg/svnstatusform.pas | 5 +++++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/components/lazsvnpkg/svnlogform.pas b/components/lazsvnpkg/svnlogform.pas index b4da24f0eb..d8d3edb98d 100644 --- a/components/lazsvnpkg/svnlogform.pas +++ b/components/lazsvnpkg/svnlogform.pas @@ -396,11 +396,12 @@ begin //message if NodeName = 'msg' then - LogItem.Msg:=ReplaceLineEndings(tmpNode.FirstChild.NodeValue, LineEnding); + if Assigned(tmpNode.FirstChild) then + LogItem.Msg:=ReplaceLineEndings(tmpNode.FirstChild.NodeValue, LineEnding); end; ActionNode := tmpNode.FirstChild; - if Assigned(ActionNode.Attributes) then + if Assigned(ActionNode) and Assigned(ActionNode.Attributes) then repeat //attributes diff --git a/components/lazsvnpkg/svnstatusform.pas b/components/lazsvnpkg/svnstatusform.pas index f015bf1198..ad0cc40e7c 100644 --- a/components/lazsvnpkg/svnstatusform.pas +++ b/components/lazsvnpkg/svnstatusform.pas @@ -106,6 +106,11 @@ var StatusItem : PSVNStatusItem; FileName: string; begin + if SVNCommitMsgMemo.Text = '' then + if MessageDlg ('No message set.', 'Do you wish to continue?', mtConfirmation, + [mbYes, mbNo],0) <> mrYes then + exit; + //commit the checked files CmdLine := SVNExecutable + ' commit --force-log ';