summaryrefslogtreecommitdiff
path: root/Net1090
diff options
context:
space:
mode:
authorArturs Artamonovs <arturs.artamonovs@protonmail.com>2024-07-19 10:50:06 +0100
committerArturs Artamonovs <arturs.artamonovs@protonmail.com>2024-07-19 10:50:06 +0100
commit6ab97d2dfe563c2c43c2519b2e6f22494572045c (patch)
tree785e403b6804960fbf52fe64f11aeedf50a05f7c /Net1090
parentb32ecfab276fb8e1dff0e1d72ed819b548323328 (diff)
downloadADSBDecoder-6ab97d2dfe563c2c43c2519b2e6f22494572045c.tar.gz
ADSBDecoder-6ab97d2dfe563c2c43c2519b2e6f22494572045c.zip
Add network configuration windows in LearnMapKit
Diffstat (limited to 'Net1090')
-rw-r--r--Net1090/main.swift9
1 files changed, 8 insertions, 1 deletions
diff --git a/Net1090/main.swift b/Net1090/main.swift
index 93ff716..04d0384 100644
--- a/Net1090/main.swift
+++ b/Net1090/main.swift
@@ -9,6 +9,7 @@ import Foundation
import Network
import NIO
+
class ADSBHandlder: ChannelInboundHandler {
typealias InboundIn = ByteBuffer
typealias OutboundOut = ByteBuffer
@@ -58,7 +59,13 @@ class TCPClient {
}
func stop() {
-
+ do {
+ try group.syncShutdownGracefully()
+ } catch let error {
+ print("Error shutting down \(error.localizedDescription)")
+ exit(0)
+ }
+ print("Connection closed")
}
}