6.0.0-beta1
7/4/25

[#8601] Warnings in current sessions due to missing arguments
Summary Warnings in current sessions due to missing arguments
Queue Horde Base
Queue Version 3.3.5
Type Bug
State Resolved
Priority 1. Low
Owners jan (at) horde (dot) org
Requester moreda (at) allenta (dot) com
Created 09/23/2009 (5763 days ago)
Due
Updated 09/25/2009 (5761 days ago)
Assigned
Resolved 09/25/2009 (5761 days ago)
Github Issue Link
Github Pull Request
Milestone 3.3.6
Patch Yes

History
09/25/2009 02:40:31 PM Jan Schneider Comment #4
Assigned to Jan Schneider
State ⇒ Resolved
Milestone ⇒ 3.3.6
Reply to this comment
Committed, thanks!
09/23/2009 05:20:33 PM moreda (at) allenta (dot) com Comment #1
Priority ⇒ 1. Low
New Attachment: fix-warning-of-null-values-in-session-handling.diff Download
Patch ⇒ Yes
Milestone ⇒
Summary ⇒ Warnings in current sessions due to missing arguments
Type ⇒ Bug
State ⇒ Unconfirmed
Queue ⇒ Horde Base
Reply to this comment
Using MSSQL as storage for sessions through PEAR's DB abstraction 
layer I found this type of messages in the "current sessions" screen:



Warning: Missing argument 1 for SessionHandler::open(), called in 
/usr/local/share/horde-3.3.5/lib/Horde/SessionHandler/sql.php on line 
307 and defined in 
/usr/local/share/horde-3.3.5/lib/Horde/SessionHandler.php on line 149



Warning: Missing argument 2 for SessionHandler::open(), called in 
/usr/local/share/horde-3.3.5/lib/Horde/SessionHandler/sql.php on line 
307 and defined in 
/usr/local/share/horde-3.3.5/lib/Horde/SessionHandler.php on line 149



Notice: Undefined variable: save_path in 
/usr/local/share/horde-3.3.5/lib/Horde/SessionHandler.php on line 155



Notice: Undefined variable: session_name in 
/usr/local/share/horde-3.3.5/lib/Horde/SessionHandler.php on line 155



These messages are derived from the lack of default null values for 
the arguments of the function open() in lib/Horde/SessionHandler.php 
(or maybe an incorrect use of this function from some other parts of 
the code).



In any case makes sense for me to apply this:



--- horde-3.3.5.orig/lib/Horde/SessionHandler.php       2009-09-23 
17:59:12.206783858 +0200

+++ horde-3.3.5/lib/Horde/SessionHandler.php    2009-09-23 
18:16:05.402784153 +0200

@@ -146,7 +146,7 @@

       *

       * @return boolean  True on success, false otherwise.

       */

-    function open($save_path, $session_name)

+    function open($save_path = null, $session_name = null)

      {

          if ($this->_connected) {

              return true;



See trivial patch attached.


Saved Queries