Skip to content

Commit ff59a8b

Browse files
committed
Added comments
1 parent 9f10d3c commit ff59a8b

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

serial.go

+2
Original file line numberDiff line numberDiff line change
@@ -239,6 +239,7 @@ func (sp *SerialPortList) remove(removedPort *discovery.Port) {
239239
})
240240
}
241241

242+
// MarkPortAsOpened marks a port as opened by the user
242243
func (sp *SerialPortList) MarkPortAsOpened(portname string) {
243244
sp.portsLock.Lock()
244245
defer sp.portsLock.Unlock()
@@ -248,6 +249,7 @@ func (sp *SerialPortList) MarkPortAsOpened(portname string) {
248249
}
249250
}
250251

252+
// MarkPortAsClosed marks a port as no more opened by the user
251253
func (sp *SerialPortList) MarkPortAsClosed(portname string) {
252254
sp.portsLock.Lock()
253255
defer sp.portsLock.Unlock()

0 commit comments

Comments
 (0)