When a user presses Ctrl-C while using ra_local, it is not
uncommon for the repository to be left in a "wedged" state.
This can be prevented by ignoring SIGINT.
It might be more appropriate to do this in ra_local->open(),
since it's really only necessary for local operations.
* subversion/clients/cmdline/main.c
(main): set the signal handler for SIGINT to SIG_IGN.
Index: subversion/clients/cmdline/main.c
===================================================================
--- subversion/clients/cmdline/main.c
+++ subversion/clients/cmdline/main.c Wed Jul 31 22:17:55 2002
@@ -29,6 +29,7 @@
#include <apr_strings.h>
#include <apr_tables.h>
#include <apr_general.h>
+#include <apr_signal.h>
#include <apr_lib.h>
#include "svn_pools.h"
@@ -894,6 +895,13 @@
return EXIT_FAILURE;
}
+ /* Ignore interrupts. This should cut down on repository wedges
+ for ra_local. */
+ if (apr_signal(SIGINT, SIG_IGN) == SIG_ERR)
+ {
+ fprintf(stderr, "error: couldn't establish signal handler\n");
+ }
+
/* Create our top-level pool. */
pool = svn_pool_create (NULL);
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Thu Aug 1 05:10:12 2002