On Mon, Jul 25, 2016 at 05:43:30AM +0200, Emmanuel Dreyfus wrote:
> Vijay Bellur wrote:
>
> > Do you have any concrete examples of problems encountered due to the
> > same directory stream being invoked from multiple threads?
>
> I am not sure this scenario can happen, but
On 07/25/2016 07:26 AM, Kaleb S. KEITHLEY wrote:
> On 07/23/2016 10:32 AM, Emmanuel Dreyfus wrote:
>> Pranith Kumar Karampuri wrote:
>>
>>> So should we do readdir() with external locks for everything instead?
>>
>> readdir() with a per-directory lock is safe. However, it may
On 07/23/2016 10:32 AM, Emmanuel Dreyfus wrote:
> Pranith Kumar Karampuri wrote:
>
>> So should we do readdir() with external locks for everything instead?
>
> readdir() with a per-directory lock is safe. However, it may come with a
> performance hit in some scenarios,
Vijay Bellur wrote:
> Do you have any concrete examples of problems encountered due to the
> same directory stream being invoked from multiple threads?
I am not sure this scenario can happen, but what we had were directory
offsets reused among different DIR * opened on the
On Sat, Jul 23, 2016 at 8:02 PM, Emmanuel Dreyfus wrote:
> Pranith Kumar Karampuri wrote:
>
> > So should we do readdir() with external locks for everything instead?
>
> readdir() with a per-directory lock is safe. However, it may come with a
> performance
Pranith Kumar Karampuri wrote:
> So should we do readdir() with external locks for everything instead?
readdir() with a per-directory lock is safe. However, it may come with a
performance hit in some scenarios, since two threads cannot read the
same directory at once. But I
Emmanuel,
I procrastinated too long on this :-/, It is July already :-(. I
just looked at the man page in Linux and it is a bit confusing, so I am not
sure how to go ahead.
For readdir_r(), I see:
DESCRIPTION
This function is deprecated; use readdir(3) instead.
The
Juste to make sure there is no misunderstanding here: unfortunately I
do not have time right now to submit a fix. It would be nice if someone
else coule look at it.
On Wed, Feb 10, 2016 at 01:48:52PM +, Emmanuel Dreyfus wrote:
> Hi
>
> After obtaining a core in a regression, I noticed there
Hi
After obtaining a core in a regression, I noticed there are a few readdir()
use in threaded code. This is begging for a crash, as readdir() maintains
an internal state that will be trashed on concurent use. readdir_r()
should be used instead.
A quick search shows readdir(à usage here: