[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
cvs tag and #cvs.lock
From: |
Paul Edwards |
Subject: |
cvs tag and #cvs.lock |
Date: |
Wed, 11 Jun 2003 09:41:03 GMT |
I was going to try out this patch today, to see if it stopped
the cvs.lock being left after multiple ctrl-c. But I was
unable to reproduce the problem. I tagged and ctrl-ced
like no tomorrow, but the thing wouldn't die like a dog.
The most I got was a silly error message. Is this a problem?
It is slightly editted, but I can tell you that "prod_adm_pkg..."
(without the ",") is indeed the next file in the list of things
to be tagged normally.
So is the bad file number a sign of a logic hole?
And any suggestion on whether the patch should be applied,
even if I can't reproduce what is basically a timing-sensitive
possible/probable bug?
BFN. Paul.
machine:user-/home/user/scratch/temptemp/admin/files% cvs tag -d tag1;cvs
tag tag1
cvs tag: Untagging .
cvs tag: Tagging .
T placeholder
^Ccvs tag: error closing lock file
/development/repository/temptemp/admin/files/,prod_adm_pkg_list.cfg,: Bad
file number
^Ccvs [tag aborted]: received interrupt signal
^Cmachine:user-/home/user/scratch/temptemp/admin/files%
machine:user-/home/user/scratch/temptemp/admin/files%
(patch against cvs1-11-6)
Index: sighandle.c
===================================================================
RCS file: /cvs/ccvs/lib/sighandle.c,v
retrieving revision 1.7
diff -c -r1.7 sighandle.c
*** sighandle.c 23 Feb 2000 10:11:25 -0000 1.7
--- sighandle.c 3 Jun 2003 13:40:37 -0000
***************
*** 150,155 ****
--- 150,175 ----
int sig;
{
struct SIG_hlist *this;
+ #ifdef POSIX_SIGNALS
+ struct sigaction act;
+ sigset_t sigset_mask, sigset_omask;
+ #else
+ #ifdef BSD_SIGNALS
+ struct sigvec vec;
+ int mask;
+ #endif
+ #endif
+
+ /* Block this signal while we look at handler chain */
+ #ifdef POSIX_SIGNALS
+ (void) sigemptyset(&sigset_mask);
+ (void) sigaddset(&sigset_mask, sig);
+ (void) sigprocmask(SIG_BLOCK, &sigset_mask, &sigset_omask);
+ #else
+ #ifdef BSD_SIGNALS
+ mask = sigblock(sigmask(sig));
+ #endif
+ #endif
/* Dispatch signal handlers */
this = SIG_handlers[sig];
***************
*** 158,163 ****
--- 178,192 ----
(*this->handler)(sig);
this = this->next;
}
+
+ /* Unblock the signal */
+ #ifdef POSIX_SIGNALS
+ (void) sigprocmask(SIG_SETMASK, &sigset_omask, NULL);
+ #else
+ #ifdef BSD_SIGNALS
+ (void) sigsetmask(mask);
+ #endif
+ #endif
return;
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- cvs tag and #cvs.lock,
Paul Edwards <=