From 6b1426f10bd0d96154ffc5a111f2e490e6900b18 Mon Sep 17 00:00:00 2001 From: Karchnu Date: Fri, 3 Jul 2020 13:48:39 +0200 Subject: [PATCH] connection type --- src/ipc/context.cr | 1 + src/ipc/lowlevel.cr | 10 ++++++++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/src/ipc/context.cr b/src/ipc/context.cr index 4687bf6..51ce20e 100644 --- a/src/ipc/context.cr +++ b/src/ipc/context.cr @@ -1,6 +1,7 @@ require "./lowlevel" require "./message" require "./event" +require "./connection" class IPC::Context property base_timer : Float64 = 0.0 diff --git a/src/ipc/lowlevel.cr b/src/ipc/lowlevel.cr index 99d1f72..f6f9585 100644 --- a/src/ipc/lowlevel.cr +++ b/src/ipc/lowlevel.cr @@ -1,9 +1,15 @@ @[Link("ipc")] lib LibIPC + enum ConnectionType + IPC + External + Server + end + struct Connection - type : UInt8 - spath : LibC::Char* # [4096] # [PATH_MAX] + type : ConnectionType # + spath : LibC::Char* # [4096] # [PATH_MAX] end struct Pollfd