  |
1 | 1 | | <?php |
| |
2 | 2 | | /* |
  |
3 | | - | $Id: session.php 1673 2007-08-09 14:25:34Z hpdl $ |
| |
| 3 | + | $Id: session.php 1846 2009-02-27 14:40:55Z hpdl $ |
|
4 | 4 | | |
| |
5 | 5 | | osCommerce, Open Source E-Commerce Solutions |
| |
6 | 6 | | http://www.oscommerce.com |
| |
7 | 7 | | |
  |
8 | | - | Copyright (c) 2007 osCommerce |
| |
| 8 | + | Copyright (c) 2009 osCommerce |
|
9 | 9 | | |
| |
10 | 10 | | This program is free software; you can redistribute it and/or modify |
| |
11 | 11 | | it under the terms of the GNU General Public License v2 (1991) |
| |
|
|
 |
… |
|
77 | 77 | | if ( SERVICE_SESSION_EXPIRATION_TIME > 0 ) { |
| |
78 | 78 | | ini_set('session.gc_maxlifetime', SERVICE_SESSION_EXPIRATION_TIME * 60); |
| |
79 | 79 | | } |
  |
80 | | - | } |
|
81 | 80 | | |
  |
82 | | - | /** |
| |
83 | | - | * Destructor, closes the session |
| |
84 | | - | * |
| |
85 | | - | * @access public |
| |
86 | | - | */ |
| |
87 | | - | |
| |
88 | | - | public function __destruct() { |
| |
89 | | - | $this->close(); |
| |
| 81 | + | register_shutdown_function(array($this, 'close')); |
  |
90 | 82 | | } |
| |
91 | 83 | | |
| |
92 | 84 | | /** |