| ... | ... | @@ -1282,14 +1282,12 @@ pub fn connectTcp(client: *Client, host: []const u8, port: u16, protocol: Connec |
| 1282 | 1282 | return &conn.data; |
| 1283 | 1283 | } |
| 1284 | 1284 | |
| 1285 | | pub const ConnectUnixError = Allocator.Error || std.os.SocketError || error{ NameTooLong, Unsupported } || std.os.ConnectError; |
| 1285 | pub const ConnectUnixError = Allocator.Error || std.os.SocketError || error{NameTooLong} || std.os.ConnectError; |
| 1286 | 1286 | |
| 1287 | 1287 | /// Connect to `path` as a unix domain socket. This will reuse a connection if one is already open. |
| 1288 | 1288 | /// |
| 1289 | 1289 | /// This function is threadsafe. |
| 1290 | 1290 | pub fn connectUnix(client: *Client, path: []const u8) ConnectUnixError!*Connection { |
| 1291 | | if (!net.has_unix_sockets) return error.Unsupported; |
| 1292 | | |
| 1293 | 1291 | if (client.connection_pool.findConnection(.{ |
| 1294 | 1292 | .host = path, |
| 1295 | 1293 | .port = 0, |