• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Why is the latest WebKit interacting with my NSThread?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Why is the latest WebKit interacting with my NSThread?


  • Subject: Re: Why is the latest WebKit interacting with my NSThread?
  • From: "Michael Dupuis" <email@hidden>
  • Date: Fri, 7 Dec 2007 07:57:00 -0500

> Since upgrading to 10.4.11 and Safari 3, I notice now that a thread in my
> application throws the following errors when an NSThread thread runs:
>
> WebKit Threading Violation - +[DOMDocument(WebCoreInternal)
> _wrapDocument:]
> called from secondary thread
>
> WebKit Threading Violation - +[DOMCSSStyleDeclaration(WebCoreInternal)
> _wrapCSSStyleDeclaration:] called from secondary thread
>
> WebKit Threading Violation - -[DOMCSSValue dealloc] called from secondary
> thread
>
> WebKit Threading Violation - -[DOMNode dealloc] called from secondary
> thread


Well after experimenting for  a bit longer after posting this, I found the
problem: I was calling

[[[NSAttributedString alloc] initWithHTML:theData documentAttributes:nil]
autorelease]


in a thread, and apparently it's now not thread-safe (or maybe it never
was). Moving this outside of my thread resolved the problem. This call must
be accessing WebKit, which I guess sort of makes sense, but I wouldn't have
expected an NSAttributedString dependancy on WebKit.
_______________________________________________

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

  • Follow-Ups:
    • Re: Why is the latest WebKit interacting with my NSThread?
      • From: Douglas Davidson <email@hidden>
  • Prev by Date: NSImage initWithContentsOfURL over SSL
  • Next by Date: Re: Trouble creating drag image from a partial view
  • Previous by thread: Re: NSImage initWithContentsOfURL over SSL
  • Next by thread: Re: Why is the latest WebKit interacting with my NSThread?
  • Index(es):
    • Date
    • Thread