Skip to content

Commit

Permalink
Removed HostController.address
Browse files Browse the repository at this point in the history
  • Loading branch information
colemancda committed May 15, 2019
1 parent 8be9720 commit a559422
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions Sources/BluetoothLinux/HostController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -26,25 +26,20 @@ public final class HostController: BluetoothHostControllerInterface {
/// The device identifier of the Bluetooth controller.
public let identifier: Identifier

/// The Bluetooth Address of the controller.
public let address: BluetoothAddress

// MARK: - Internal Properties

internal let internalSocket: CInt

// MARK: - Initizalization

deinit {

close(internalSocket)
}

/// Attempt to initialize an controller controller
public init(identifier: Identifier) throws {

self.identifier = identifier
self.address = try BluetoothAddress(deviceIdentifier: identifier)
self.internalSocket = try HCIOpenDevice(identifier)
}

Expand All @@ -55,7 +50,6 @@ public final class HostController: BluetoothHostControllerInterface {
else { throw Error.adapterNotFound }

self.identifier = deviceIdentifier
self.address = address
self.internalSocket = try HCIOpenDevice(deviceIdentifier)
}
}
Expand Down

0 comments on commit a559422

Please sign in to comment.