The Samba-Bugzilla – Attachment 17844 Details for
Bug 15342
Spotlight sometimes returns no results on latest macOS
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Possible patch for master
master-bug15342-spotlight-pending-queries.patch (text/plain), 1.36 KB, created by
Ralph Böhme
on 2023-03-23 17:49:38 UTC
(
hide
)
Description:
Possible patch for master
Filename:
MIME Type:
Creator:
Ralph Böhme
Created:
2023-03-23 17:49:38 UTC
Size:
1.36 KB
patch
obsolete
>From b7db51ba2061e0ea4bada15f869439997cd79b52 Mon Sep 17 00:00:00 2001 >From: Ralph Boehme <slow@samba.org> >Date: Thu, 23 Mar 2023 16:39:11 +0100 >Subject: [PATCH] mdssvc: fix long running backend queries > >If a query is still running in the backend and we have no results yet, returning >0 triggers a search termination by the client in latest macOS releases. macOS >returns 0x23 in this case. > >BUG: https://bugzilla.samba.org/show_bug.cgi?id=15342 >--- > source3/rpc_server/mdssvc/mdssvc.c | 13 ++++++++++++- > 1 file changed, 12 insertions(+), 1 deletion(-) > >diff --git a/source3/rpc_server/mdssvc/mdssvc.c b/source3/rpc_server/mdssvc/mdssvc.c >index 9b32c99b8b3a..24811703fb8c 100644 >--- a/source3/rpc_server/mdssvc/mdssvc.c >+++ b/source3/rpc_server/mdssvc/mdssvc.c >@@ -306,10 +306,21 @@ static bool create_result_handle(struct sl_query *slq) > static bool add_results(sl_array_t *array, struct sl_query *slq) > { > sl_filemeta_t *fm; >- uint64_t status = 0; >+ uint64_t status; > int result; > bool ok; > >+ /* >+ * Taken from a network trace against a macOS SMB Spotlight server. If >+ * the first fetch-query-results has no results yet because the search >+ * is still running, macOS returns 0x23, otherwise 0x0. >+ */ >+ if (slq->state == SLQ_STATE_DONE) { >+ status = 0; >+ } else { >+ status = 0x23; >+ } >+ > /* FileMeta */ > fm = dalloc_zero(array, sl_filemeta_t); > if (fm == NULL) { >-- >2.39.2 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 15342
:
17844
|
18008