Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 38784
b: refs/heads/master
c: 0644244
h: refs/heads/master
v: v3
  • Loading branch information
David Teigland authored and Steven Whitehouse committed Aug 9, 2006
1 parent 6d0c230 commit 5fab82d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: f6db1b8e724b071d144055b48da3827ce26dba1c
refs/heads/master: 06442440bc442ef79cb060c6e786eaeeabd9044b
11 changes: 7 additions & 4 deletions trunk/fs/dlm/debug_fs.c
Original file line number Diff line number Diff line change
Expand Up @@ -310,16 +310,19 @@ static ssize_t waiters_read(struct file *file, char __user *userbuf,
{
struct dlm_ls *ls = file->private_data;
struct dlm_lkb *lkb;
size_t len = DLM_DEBUG_BUF_LEN, pos = 0, rv;
size_t len = DLM_DEBUG_BUF_LEN, pos = 0, ret, rv;

mutex_lock(&debug_buf_lock);
mutex_lock(&ls->ls_waiters_mutex);
memset(debug_buf, 0, sizeof(debug_buf));

list_for_each_entry(lkb, &ls->ls_waiters, lkb_wait_reply) {
pos += snprintf(debug_buf + pos, len - pos, "%x %d %d %s\n",
lkb->lkb_id, lkb->lkb_wait_type,
lkb->lkb_nodeid, lkb->lkb_resource->res_name);
ret = snprintf(debug_buf + pos, len - pos, "%x %d %d %s\n",
lkb->lkb_id, lkb->lkb_wait_type,
lkb->lkb_nodeid, lkb->lkb_resource->res_name);
if (ret >= len - pos)
break;
pos += ret;
}
mutex_unlock(&ls->ls_waiters_mutex);

Expand Down

0 comments on commit 5fab82d

Please sign in to comment.