On Jul 25, 2016, at 9:37 PM, Daniel Stenmark wrote:
1. Can I write to two different files using two NSFIleHandles from
two threads at the same time?
Yes.
2. Can I read from a single file using two NSFileHandles on two
threads at the same time?
Why would you need to do that in the first
> As long as each thread has a separate file handle, they’re independent of
> each other, since each file handle remembers its own offset in the file.
Ah, durr, you’re right. Apologies, I once had the displeasure of debugging an
ancient codebase that used the same Unix file descriptor with
> On Jul 25, 2016, at 12:37 PM, Daniel Stenmark wrote:
>
> 2. Can I read from a single file using two NSFileHandles on two threads at
> the same time?
>
> Why would you need to do that in the first place?
To get multithreaded access to the file contents. This is
> On 26 Jul 2016, at 5:37 AM, Daniel Stenmark wrote:
>
> 2. Can I read from a single file using two NSFileHandles on two threads at
> the same time?
>
> Why would you need to do that in the first place? Unless you’re reading a
> single byte at a time, it sounds like
1. Can I write to two different files using two NSFIleHandles from two threads
at the same time?
Yes.
2. Can I read from a single file using two NSFileHandles on two threads at the
same time?
Why would you need to do that in the first place? Unless you’re reading a
single byte at a time, it