[anjuta] Subversion: Don't crash if no paths are selected for committing.
- From: James Liggett <jrliggett src gnome org>
- To: svn-commits-list gnome org
- Subject: [anjuta] Subversion: Don't crash if no paths are selected for committing.
- Date: Fri, 15 May 2009 22:57:07 -0400 (EDT)
commit e33b3b7f701b8b13cd0170cfe166b0535399d92c
Author: James Liggett <jrliggett cox net>
Date: Fri May 15 19:48:56 2009 -0700
Subversion: Don't crash if no paths are selected for committing.
Fixes bug 582825 â?? Anjuta crashes when there is no selected/changed file in the commit dialog
---
plugins/subversion/svn-commit-command.c | 16 ++++++++++------
1 files changed, 10 insertions(+), 6 deletions(-)
diff --git a/plugins/subversion/svn-commit-command.c b/plugins/subversion/svn-commit-command.c
index c7b774b..c0d1d2e 100644
--- a/plugins/subversion/svn-commit-command.c
+++ b/plugins/subversion/svn-commit-command.c
@@ -98,6 +98,7 @@ svn_commit_command_run (AnjutaCommand *command)
commit_paths = apr_array_make (svn_command_get_pool (svn_command),
g_list_length (self->priv->paths),
sizeof (char *));
+ error = NULL;
while (current_path)
{
@@ -106,12 +107,15 @@ svn_commit_command_run (AnjutaCommand *command)
current_path = g_list_next (current_path);
}
- error = svn_client_commit3 (&commit_info,
- commit_paths,
- self->priv->recursive,
- TRUE,
- svn_command_get_client_context (svn_command),
- svn_command_get_pool (svn_command));
+ if (self->priv->paths)
+ {
+ error = svn_client_commit3 (&commit_info,
+ commit_paths,
+ self->priv->recursive,
+ TRUE,
+ svn_command_get_client_context (svn_command),
+ svn_command_get_pool (svn_command));
+ }
if (error)
{
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]