rbb 99/11/12 15:51:12
Modified: src/lib/apr/locks/unix crossproc.c
Log:
Fix some obvious typos in the lock logic. I'm not sure how this ever worked.
Revision Changes Path
1.8 +10 -10 apache-2.0/src/lib/apr/locks/unix/crossproc.c
Index: crossproc.c
===================================================================
RCS file: /home/cvs/apache-2.0/src/lib/apr/locks/unix/crossproc.c,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- crossproc.c 1999/10/12 06:14:45 1.7
+++ crossproc.c 1999/11/12 23:51:10 1.8
@@ -95,14 +95,14 @@
new->op_off.sem_op = 1;
new->op_off.sem_flg = SEM_UNDO;
- new->curr_locked == 0;
+ new->curr_locked = 0;
ap_register_cleanup(new->cntxt, (void *)new, lock_cleanup,
ap_null_cleanup);
return APR_SUCCESS;
}
ap_status_t lock_inter(struct lock_t *lock)
{
- new->curr_locked == 1;
+ new->curr_locked = 1;
if (semop(lock->interproc, &lock->op_on, 1) < 0) {
return errno;
}
@@ -114,7 +114,7 @@
if (semop(lock->interproc, &lock->op_off, 1) < 0) {
return errno;
}
- new->curr_locked == 0;
+ new->curr_locked = 0;
return APR_SUCCESS;
}
@@ -187,7 +187,7 @@
return stat;
}
- new->curr_locked == 0;
+ new->curr_locked = 0;
ap_register_cleanup(new->cntxt, (void *)new, lock_cleanup,
ap_null_cleanup);
return APR_SUCCESS;
}
@@ -195,7 +195,7 @@
ap_status_t lock_inter(struct lock_t *lock)
{
ap_status_t stat;
- new->curr_locked == 1;
+ new->curr_locked = 1;
if (stat = pthread_mutex_lock(lock->interproc)) {
return stat;
}
@@ -209,7 +209,7 @@
if (stat = pthread_mutex_unlock(lock->interproc)) {
returno stat;
}
- new->curr_locked == 0;
+ new->curr_locked = 0;
return APR_SUCCESS;
}
@@ -309,7 +309,7 @@
if (flock(lock->interproc, LOCK_UN) < 0) {
return errno;
}
- lock->curr_locked == 0;
+ lock->curr_locked = 0;
}
unlink(lock->fname);
return APR_SUCCESS;
@@ -323,14 +323,14 @@
lock_cleanup(new);
return errno;
}
- new->curr_locked == 0;
+ new->curr_locked = 0;
ap_register_cleanup(new->cntxt, (void *)new, lock_cleanup,
ap_null_cleanup);
return APR_SUCCESS;
}
ap_status_t lock_inter(struct lock_t *lock)
{
- lock->curr_locked == 1;
+ lock->curr_locked = 1;
if (flock(lock->interproc, LOCK_EX) < 0) {
return errno;
}
@@ -342,7 +342,7 @@
if (flock(lock->interproc, LOCK_UN) < 0) {
return errno;
}
- lock->curr_locked == 0;
+ lock->curr_locked = 0;
return APR_SUCCESS;
}