Re: SKIndexAddDocument crashing
Re: SKIndexAddDocument crashing
- Subject: Re: SKIndexAddDocument crashing
- From: email@hidden
- Date: Thu, 14 Nov 2013 08:14:07 -0600
If anyone is watching who can expedite this, I have started a DTS
incident.
This does appear to be a serious bug in Search Kit.
On 2013-11-14 07:41, Aaron Burghardt wrote:
On Nov 8, 2013, at 9:27 AM, Mark Wright <email@hidden>
wrote:
It doesn’t crash if you replace the crashing line with:
SKIndexAddDocumentWithText(searchIndexFile, doc, NULL, false);
For the record, this doesn't crash but it doesn't index the content,
either. it is up to the developer to extract the text content and pass
it to that function.
I think it’s failing because it’s not recognising the file type as
text (see the docs - option click the function).
It doesn’t crash if you supply the mimeTypeHint:
SKIndexAddDocument( searchIndexFile, doc, (__bridge
CFStringRef)@"txt", false );
This also fails to index the content; it only adds a file reference to
the index. Some experimentation suggests that the parameter must be a
MIME type, as documented, and UTIs are ignored. This succeeds in
indexing the content:
SKIndexAddDocument( searchIndexFile, doc, CFSTR("text/plain"), false
);
but it indexes the raw email source, so there is a lot of noise and
encoded text is not decoded and thus is not a great solution for the
example email in the test project.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden