Re: Re: [VOTE] Introduce session.lock, session.lazy_write and session.lazy_destory

From: Date: Thu, 30 Jan 2014 07:39:28 +0000
Subject: Re: Re: [VOTE] Introduce session.lock, session.lazy_write and session.lazy_destory
References: 1 2 3 4  Groups: php.internals 
Request: Send a blank email to internals+get-71787@lists.php.net to get a copy of this message
Hi Patrick, On Thu, Jan 30, 2014 at 4:30 PM, Patrick Schaaf <php@bof.de> wrote: > I don't see that. You mean by the call to ps_files_close() within > ps_files_open(), and that close() call dropping the lock? That is > conditional > on either data->fd < 0 (no file open, just a superfluous call to > ps_file_close()), or key != lastkey (and then a _different_ file will be > opened and locked for writing). > Next request may read closed session data which is no longer valid. When it is destroyed or regenerated session with new code, it will be handled by lazy_destroy. So it's not a problem. When session is not destroyed or regenerated, close call in PS_WRITE unlocks file then next request starts reading it. This could happen before writing data by previous request. I don't have access to the code right now, so I have to double check though. Regards, -- Yasuo Ohgaki yohgaki@ohgaki.net

« previous php.internals (#71787) next »