fixed indent

This commit is contained in:
Cristian Maglie
2014-12-13 20:05:40 +04:30
parent c0438ea53f
commit 8ccb774c5d

View File

@@ -232,17 +232,17 @@ func OpenPort(portName string, exclusive bool) (SerialPort, error) {
settings.c_oflag &= ^C.tcflag_t(C.OPOST) settings.c_oflag &= ^C.tcflag_t(C.OPOST)
// Block reads until at least one char is available (no timeout) // Block reads until at least one char is available (no timeout)
settings.c_cc[C.VMIN] = 1; settings.c_cc[C.VMIN] = 1
settings.c_cc[C.VTIME] = 0; settings.c_cc[C.VTIME] = 0
err = setTermSettings(handle, settings) err = setTermSettings(handle, settings)
if err != nil { if err != nil {
syscall.Close(handle) syscall.Close(handle)
return nil, &SerialPortError{code: ERROR_INVALID_SERIAL_PORT} return nil, &SerialPortError{code: ERROR_INVALID_SERIAL_PORT}
} }
/* /*
settings->c_cflag &= ~CRTSCTS; settings->c_cflag &= ~CRTSCTS;
*/ */
syscall.SetNonblock(handle, false) syscall.SetNonblock(handle, false)
if exclusive { if exclusive {