summaryrefslogtreecommitdiff
path: root/source3/smbd
diff options
context:
space:
mode:
authorVolker Lendecke <vl@samba.org>2012-10-31 13:13:50 +0100
committerStefan Metzmacher <metze@samba.org>2013-03-26 13:16:39 +0100
commite3f5e474c826940ebaf43256cb06a50309ba3ef5 (patch)
tree0b92dbae23d8dc95223d6715121ed24461c774b6 /source3/smbd
parent07ae7e22f789a67bbd5e9536e1227a1c394990f9 (diff)
downloadsamba-e3f5e474c826940ebaf43256cb06a50309ba3ef5.tar.gz
samba-e3f5e474c826940ebaf43256cb06a50309ba3ef5.tar.bz2
samba-e3f5e474c826940ebaf43256cb06a50309ba3ef5.zip
smbd: Remove an optimization that became unnecessary
After we only collect nonlocal vnns in idx_state.vnns now, at this point we *know* we have something to send to a remote node. The previous code avoided the call to notify_push_remote_blob with an if-statement that has now become unnecessary. Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Autobuild-User(master): Stefan Metzmacher <metze@samba.org> Autobuild-Date(master): Tue Mar 26 13:16:39 CET 2013 on sn-devel-104
Diffstat (limited to 'source3/smbd')
-rw-r--r--source3/smbd/notify_internal.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/source3/smbd/notify_internal.c b/source3/smbd/notify_internal.c
index ee6f4cc870..2dc86748d9 100644
--- a/source3/smbd/notify_internal.c
+++ b/source3/smbd/notify_internal.c
@@ -662,7 +662,12 @@ void notify_trigger(struct notify_context *notify,
qsort(idx_state.vnns, num_vnns, sizeof(uint32_t), vnn_cmp);
last_vnn = 0xffffffff;
- remote_blob = NULL;
+
+ if (!notify_push_remote_blob(talloc_tos(), action, filter, path,
+ &remote_blob, &remote_blob_len)) {
+ DEBUG(1, ("notify_push_remote_blob failed\n"));
+ goto done;
+ }
for (i=0; i<num_vnns; i++) {
uint32_t vnn = idx_state.vnns[i];
@@ -671,12 +676,6 @@ void notify_trigger(struct notify_context *notify,
if (vnn == last_vnn) {
continue;
}
- if ((remote_blob == NULL) &&
- !notify_push_remote_blob(
- talloc_tos(), action, filter,
- path, &remote_blob, &remote_blob_len)) {
- break;
- }
status = ctdbd_messaging_send_blob(
ctdbd_conn, vnn, CTDB_SRVID_SAMBA_NOTIFY_PROXY,