Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:7668 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 25114 invoked by uid 1010); 9 Feb 2004 16:06:27 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 25079 invoked from network); 9 Feb 2004 16:06:26 -0000 Received: from unknown (HELO sapo.pt) (212.55.154.26) by pb1.pair.com with SMTP; 9 Feb 2004 16:06:26 -0000 Received: (qmail 5943 invoked from network); 9 Feb 2004 16:06:25 -0000 Received: from unknown (HELO sapo.pt) (10.134.35.153) by relay6 with SMTP; 9 Feb 2004 16:06:25 -0000 Received: (qmail 4005 invoked from network); 9 Feb 2004 16:04:28 -0000 Received: from unknown (HELO pc07653) (nunoplopes@sapo.pt@[81.193.139.16]) (envelope-sender ) by mta3 (qmail-ldap-1.03) with SMTP for ; 9 Feb 2004 16:04:28 -0000 Message-ID: <008701c3ef27$0cd6e9c0$0100a8c0@pc07653> To: "PHPdev" Date: Mon, 9 Feb 2004 16:09:02 -0000 MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_NextPart_000_0084_01C3EF27.08B92420" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1158 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165 Subject: [PATCH] fix #23432 From: nlopess@php.net ("Nuno Lopes") ------=_NextPart_000_0084_01C3EF27.08B92420 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Hi, As I don't have sufficient karma, here is a patch to fix bug #23432 (PHP using mtime instead of atime to clean session files). Nuno ------=_NextPart_000_0084_01C3EF27.08B92420 Content-Type: text/plain; name="diff.txt" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="diff.txt" Index: mod_files.c =================================================================== RCS file: /repository/php-src/ext/session/mod_files.c,v retrieving revision 1.94 diff -u -r1.94 mod_files.c --- mod_files.c 8 Jan 2004 08:17:23 -0000 1.94 +++ mod_files.c 9 Feb 2004 16:02:57 -0000 @@ -215,7 +215,7 @@ buf[dirname_len + entry_len + 1] = '\0'; /* check whether its last access was more than maxlifet ago */ if (VCWD_STAT(buf, &sbuf) == 0 && - (now - sbuf.st_mtime) > maxlifetime) { + (now - sbuf.st_atime) > maxlifetime) { VCWD_UNLINK(buf); nrdels++; } ------=_NextPart_000_0084_01C3EF27.08B92420--