aboutsummaryrefslogtreecommitdiffstats
path: root/fs/dlm/lock.c
diff options
context:
space:
mode:
authorDavid Teigland <teigland@redhat.com>2007-01-24 11:11:45 -0500
committerSteven Whitehouse <swhiteho@redhat.com>2007-02-05 13:37:47 -0500
commit8fd3a98f2c22982aff4d29e4ee72959d3032c123 (patch)
tree9d4b75dc24d506572d7f2700f0d68f568969e62d /fs/dlm/lock.c
parentf1f1c1ccf7848a6e25db30ee9216e1a1e7eb6bef (diff)
[DLM] saved dlm message can be dropped
dlm_receive_message() returns 0 instead of returning 'error'. What would happen is that process_requestqueue would take a saved message off the requestqueue and call receive_message on it. receive_message would then see that recovery had been aborted, set error to EINTR, and 'goto out', expecting that the error would be returned. Instead, 0 was always returned, so process_requestqueue would think that the message had been processed and delete it instead of saving it to process next time. This means the message (usually an unlock in my tests) would be lost. Signed-off-by: David Teigland <teigland@redhat.com> Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
Diffstat (limited to 'fs/dlm/lock.c')
-rw-r--r--fs/dlm/lock.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/dlm/lock.c b/fs/dlm/lock.c
index 6ad2b8eb96a5..7c7ac2aaa8b1 100644
--- a/fs/dlm/lock.c
+++ b/fs/dlm/lock.c
@@ -3018,7 +3018,7 @@ int dlm_receive_message(struct dlm_header *hd, int nodeid, int recovery)
3018{ 3018{
3019 struct dlm_message *ms = (struct dlm_message *) hd; 3019 struct dlm_message *ms = (struct dlm_message *) hd;
3020 struct dlm_ls *ls; 3020 struct dlm_ls *ls;
3021 int error; 3021 int error = 0;
3022 3022
3023 if (!recovery) 3023 if (!recovery)
3024 dlm_message_in(ms); 3024 dlm_message_in(ms);
@@ -3135,7 +3135,7 @@ int dlm_receive_message(struct dlm_header *hd, int nodeid, int recovery)
3135 out: 3135 out:
3136 dlm_put_lockspace(ls); 3136 dlm_put_lockspace(ls);
3137 dlm_astd_wake(); 3137 dlm_astd_wake();
3138 return 0; 3138 return error;
3139} 3139}
3140 3140
3141 3141