OSDN Git Service

Success build TortoiseMerge.
[tortoisegit/TortoiseGitJp.git] / src / TortoiseMerge / Patch.cpp
index 1ec32ed..79ea336 100644 (file)
@@ -1,6 +1,6 @@
 // TortoiseMerge - a Diff/Patch program\r
 \r
-// Copyright (C) 2004-2008 - TortoiseSVN\r
+// Copyright (C) 2004-2009 - TortoiseSVN\r
 \r
 // This program is free software; you can redistribute it and/or\r
 // modify it under the terms of the GNU General Public License\r
@@ -22,7 +22,7 @@
 #include "DirFileEnum.h"\r
 #include "TortoiseMerge.h"\r
 #include "svn_wc.h"\r
-#include "SVNAdminDir.h"\r
+#include "GitAdminDir.h"\r
 #include "Patch.h"\r
 \r
 #ifdef _DEBUG\r
@@ -609,6 +609,8 @@ BOOL CPatch::PatchFile(const CString& sPath, const CString& sSavePath, const CSt
                                        {\r
                                                if ((lAddLine < PatchLines.GetCount())&&(sPatchLine.Compare(PatchLines.GetAt(lAddLine))==0))\r
                                                        lAddLine++;\r
+                                               else if (((lAddLine + 1) < PatchLines.GetCount())&&(sPatchLine.Compare(PatchLines.GetAt(lAddLine+1))==0))\r
+                                                       lAddLine += 2;\r
                                                else if ((lRemoveLine < PatchLines.GetCount())&&(sPatchLine.Compare(PatchLines.GetAt(lRemoveLine))==0))\r
                                                        lRemoveLine++;\r
                                                else\r
@@ -678,7 +680,7 @@ CString     CPatch::CheckPatchPath(const CString& path)
        {\r
                if (!isDir)\r
                        continue;\r
-               if (g_SVNAdminDir.IsAdminDirPath(subpath))\r
+               if (g_GitAdminDir.IsAdminDirPath(subpath))\r
                        continue;\r
                if (CountMatches(subpath) > (GetNumberOfFiles()/3))\r
                        return subpath;\r