Commit a63273d4 authored by Andy Grover's avatar Andy Grover

RDS: Clear up some confusing code in send_remove_from_sock

The previous code was correct, but made the assumption that
if r_notifier was non-NULL then either r_recverr or r_notify
was true. Valid, but fragile. Changed to explicitly check
r_recverr (shows up in greps for recverr now, too.)
Signed-off-by: default avatarAndy Grover <andy.grover@oracle.com>
parent f4dd96f7
...@@ -551,7 +551,7 @@ void rds_send_remove_from_sock(struct list_head *messages, int status) ...@@ -551,7 +551,7 @@ void rds_send_remove_from_sock(struct list_head *messages, int status)
rds_send_sndbuf_remove(rs, rm); rds_send_sndbuf_remove(rs, rm);
if (ro->r_active && ro->r_notifier && if (ro->r_active && ro->r_notifier &&
(status || ro->r_notify)) { (ro->r_notify || (ro->r_recverr && status))) {
notifier = ro->r_notifier; notifier = ro->r_notifier;
list_add_tail(&notifier->n_list, list_add_tail(&notifier->n_list,
&rs->rs_notify_queue); &rs->rs_notify_queue);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment