enum brl_type lock_type,
enum brl_flavour lock_flav,
bool blocking_lock,
+ struct server_id *blocker_pid,
uint64_t *psmblctx)
{
NTSTATUS ret;
/* If we're returning an error, return who blocked us. */
if (!NT_STATUS_IS_OK(ret) && psmblctx) {
+ *blocker_pid = lock.context.pid;
*psmblctx = lock.context.smblctx;
}
return ret;
uint64_t *psmblctx)
{
struct byte_range_lock *br_lck = NULL;
+ struct server_id blocker_pid;
/* silently return ok on print files as we don't do locking there */
if (fsp->print_file) {
lock_type,
lock_flav,
blocking_lock,
+ &blocker_pid,
psmblctx);
DEBUG(10, ("do_lock: returning status=%s\n", nt_errstr(*perr)));
enum brl_type lock_type,
enum brl_flavour lock_flav,
bool blocking_lock,
+ struct server_id *blocker_pid,
uint64_t *psmblctx);
bool brl_unlock(struct messaging_context *msg_ctx,
struct byte_range_lock *br_lck,
{
struct smbd_server_connection *sconn = req->sconn;
struct blocking_lock_record *blr;
+ struct server_id blocker_pid;
NTSTATUS status;
if (req->smb2req) {
lock_type == READ_LOCK ? PENDING_READ_LOCK : PENDING_WRITE_LOCK,
blr->lock_flav,
True,
+ &blocker_pid,
NULL);
if (!NT_STATUS_IS_OK(status)) {
&blr->blocking_smblctx);
if (ERROR_WAS_LOCK_DENIED(status) && !lock_timeout) {
+ struct server_id blocker_pid;
/*
* If we didn't timeout, but still need to wait,
* re-add the pending lock entry whilst holding
PENDING_WRITE_LOCK,
blr->lock_flav,
true, /* Blocking lock. */
+ &blocker_pid,
NULL);
if (!NT_STATUS_IS_OK(status1)) {
&status,
&blr->blocking_smblctx);
if (ERROR_WAS_LOCK_DENIED(status) && !lock_timeout) {
+ struct server_id blocker_pid;
/*
* If we didn't timeout, but still need to wait,
* re-add the pending lock entry whilst holding
PENDING_WRITE_LOCK,
blr->lock_flav,
true, /* Blocking lock. */
+ &blocker_pid,
NULL);
if (!NT_STATUS_IS_OK(status1)) {
struct tevent_req *req = NULL;
struct smbd_smb2_lock_state *state = NULL;
struct blocking_lock_record *blr = NULL;
+ struct server_id blocker_pid;
NTSTATUS status = NT_STATUS_OK;
if (!smb2req) {
lock_type == READ_LOCK ? PENDING_READ_LOCK : PENDING_WRITE_LOCK,
blr->lock_flav,
true,
+ &blocker_pid,
NULL);
if (!NT_STATUS_IS_OK(status)) {