FWIW it crashes on mine too (not too surprising, same Xcode and OS).
It doesn’t crash if you replace the crashing line with:
SKIndexAddDocumentWithText(searchIndexFile, doc, NULL, false);
I don’t know if that’s any use to you (never used the framework).
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 );
…
On 07 Nov 2013, at 12:18, Eric Gorr <[email protected]> wrote:
> The values are all valid. There is not much more to the sample test project
> then the code I posted if you wanted to check this out yourself. The sample
> project is just the default cocoa app. At least one other person did and saw
> the same behavior
>
> Sent from my iPhone
>
>> On Nov 7, 2013, at 12:12 AM, Jerry Krinock <[email protected]> wrote:
>>
>> Forgive me if you’ve already done this, Eric, but you didn’t say if you did
>> this…
>>
>> When a function in an SDK crashes, the first thing you should do is check
>> the parameters you’re feeding it. In this case, are your local variables
>> searchIndexFile and doc valid? At least, not NULL?
>>
>>
>> _______________________________________________
>>
>> Cocoa-dev mailing list ([email protected])
>>
>> 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:
>> https://lists.apple.com/mailman/options/cocoa-dev/mailist%40ericgorr.net
>>
>> This email sent to [email protected]
>
> _______________________________________________
>
> Cocoa-dev mailing list ([email protected])
>
> 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:
> https://lists.apple.com/mailman/options/cocoa-dev/blue.buconero%40virgin.net
>
> This email sent to [email protected]
_______________________________________________
Cocoa-dev mailing list ([email protected])
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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com
This email sent to [email protected]