6.0.0-alpha14
7/2/25

[#6396] ssh2 fails for non EN locale
Summary ssh2 fails for non EN locale
Queue Horde Framework Packages
Queue Version HEAD
Type Bug
State Resolved
Priority 2. Medium
Owners chuck (at) horde (dot) org
Requester michael-dev (at) fami-braun (dot) de
Created 03/07/2008 (6326 days ago)
Due
Updated 03/07/2008 (6326 days ago)
Assigned 03/07/2008 (6326 days ago)
Resolved 03/07/2008 (6326 days ago)
Github Issue Link
Github Pull Request
Milestone 3.2
Patch No

History
03/07/2008 10:04:11 PM Chuck Hagenbuch Comment #3
Assigned to Chuck Hagenbuch
Taken from Horde DevelopersHorde Developers
State ⇒ Resolved
Reply to this comment
Looks okay to me - committed, thanks!
03/07/2008 01:05:34 PM Jan Schneider Assigned to Horde DevelopersHorde Developers
Milestone ⇒ 3.2
State ⇒ Assigned
 
03/07/2008 12:38:27 PM michael-dev (at) fami-braun (dot) de Comment #2 Reply to this comment
LC_TIME instead of LC_ALL would be sufficient.
03/07/2008 12:36:39 PM michael-dev (at) fami-braun (dot) de Comment #1
Priority ⇒ 2. Medium
Type ⇒ Bug
Summary ⇒ ssh2 fails for non EN locale
Queue ⇒ Horde Framework Packages
State ⇒ Unconfirmed
Reply to this comment
My server has got an non-us locale and ls therefore does not print the 
expected date format in VFS/ssh2.php.

Solution: Change

$stream = @ssh2_exec($this->_stream, "ls -al ".escapeshellarg($path));

and

$stream = @ssh2_exec($this->_stream, "ls -l ".escapeshellarg($path));



into



$stream = @ssh2_exec($this->_stream, "LC_ALL=C ls -al 
".escapeshellarg($path));

and

$stream = @ssh2_exec($this->_stream, "LC_ALL=C ls -l ".escapeshellarg($path));



This sets the locale to the default and works for me.

Saved Queries