Commit 98306551 authored by catch's avatar catch
Browse files

Issue #538426 by mikeytown2: Enable socket connections.

parent 3847c1df
......@@ -364,6 +364,14 @@ function dmemcache_object($bin = NULL, $flush = FALSE) {
if ($c == $cluster) {
list($host, $port) = explode(':', $s);
// Support unix sockets in the format 'unix:///path/to/socket'.
if ($host == 'unix') {
// When using unix sockets use the full path for $host.
$host = $s;
// Port is always 0 for unix sockets.
$port = 0;
}
// Using the Memcache PECL extension.
if ($memcache instanceof Memcache) {
// When using the PECL memcache extension, we must use ->(p)connect
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment