• 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
NSFileHandle and thread safety
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSFileHandle and thread safety


  • Subject: NSFileHandle and thread safety
  • From: "J.E. Schotsman" <email@hidden>
  • Date: Mon, 25 Jul 2016 21:13:45 +0200

Hello list,

I find Apple’s documentation on this unclear. It says:

"NSFileHandle, NSData, Cocoa streams:

Most of the Foundation objects you use to read and write file data can be used from any single thread but should not be used from multiple threads simultaneously."

For example I would like to know:

1. Can I write to two different files using two NSFIleHandles from two threads at the same time?
2. Can I read from a single file using two NSFileHandles on two threads at the same time?

TIA,

Jan E.


_______________________________________________

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: NSFileHandle and thread safety
      • From: Daniel Stenmark <email@hidden>
  • Prev by Date: Re: awakeFromFetch behaviour change in 10.12?
  • Next by Date: Re: NSFileHandle and thread safety
  • Previous by thread: Re: awakeFromFetch behaviour change in 10.12?
  • Next by thread: Re: NSFileHandle and thread safety
  • Index(es):
    • Date
    • Thread