fixed bug handling diff for targetPath.