Skip to content

Commit b8e8e30

Browse files
author
Marc Stern
committed
Fixed parameters/functions names
1 parent bd54f01 commit b8e8e30

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

apache2/modsecurity.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ int msr_global_mutex_lock(modsec_rec* msr, apr_global_mutex_t* lock, const char*
179179
return -1;
180180
}
181181

182-
int rc = apr_global_mutex_lock(msr->modsecurity->auditlog_lock);
182+
int rc = apr_global_mutex_lock(lock);
183183
if (rc != APR_SUCCESS) msr_log(msr, 1, "Audit log: Failed to lock global mutex: %s", get_apr_error(msr->mp, rc));
184184
return rc;
185185
}
@@ -195,7 +195,7 @@ int msr_global_mutex_unlock(modsec_rec* msr, apr_global_mutex_t* lock, const cha
195195
return -1;
196196
}
197197

198-
int rc = apr_global_mutex_unlock(msr->modsecurity->auditlog_lock);
198+
int rc = apr_global_mutex_unlock(lock);
199199
// We should have get the warning at lock time, so ignore it here
200200
// if (rc != APR_SUCCESS) msr_log(msr, 1, "Audit log: Failed to unlock global mutex: %s", get_apr_error(msr->mp, rc));
201201
return rc;

apache2/msc_logging.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -1465,7 +1465,7 @@ void sec_audit_logger_json(modsec_rec *msr) {
14651465
*/
14661466
if (msr->txcfg->auditlog_type != AUDITLOG_CONCURRENT) {
14671467
/* Unlock the mutex we used to serialise access to the audit log file. */
1468-
msr_global_mutex_lock(msr, msr->modsecurity->auditlog_lock, "Audit log");
1468+
msr_global_mutex_unlock(msr, msr->modsecurity->auditlog_lock, "Audit log");
14691469
return;
14701470
}
14711471

@@ -2236,7 +2236,7 @@ void sec_audit_logger_native(modsec_rec *msr) {
22362236
if (msr->txcfg->auditlog_type != AUDITLOG_CONCURRENT) {
22372237
sec_auditlog_write(msr, "\n", 1);
22382238
/* Unlock the mutex we used to serialise access to the audit log file. */
2239-
msr_global_mutex_lock(msr, msr->modsecurity->auditlog_lock, "Audit log");
2239+
msr_global_mutex_unlock(msr, msr->modsecurity->auditlog_lock, "Audit log");
22402240
return;
22412241
}
22422242

0 commit comments

Comments
 (0)