This is a silly combination, but at least try and keep the results sensible
and avoid a double-dereference.
BUG: https://bugzilla.samba.org/show_bug.cgi?id=14364
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Gary Lockyer <gary@catalyst.net.nz>
if (control->oid == NULL) {
break;
}
+ /*
+ * Do not re-use VLV, nor the server-sort, both are
+ * already handled here.
+ */
if (strcmp(control->oid, LDB_CONTROL_VLV_REQ_OID) == 0 ||
strcmp(control->oid, LDB_CONTROL_SERVER_SORT_OID) == 0) {
continue;
}
+ /*
+ * ASQ changes everything, do not copy it down for the
+ * per-GUID search
+ */
+ if (strcmp(control->oid, LDB_CONTROL_ASQ_OID) == 0) {
+ continue;
+ }
new_controls[j] = talloc_steal(new_controls, control);
j++;
}