Skip to content

Commit

Permalink
Fix applyModemBitsStatus (unix) (#42)
Browse files Browse the repository at this point in the history
Use IoctlSetPointerInt instead of IoctlSetInt

closes #41
  • Loading branch information
milabs authored Jan 28, 2024
1 parent 9b94bc9 commit bbd0159
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion serial_unix.go
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,7 @@ func (p *Port) retrieveModemBitsStatus() (int, error) {
}

func (p *Port) applyModemBitsStatus(status int) error {
if err := unix.IoctlSetInt(p.internal.handle, unix.TIOCMSET, status); err != nil {
if err := unix.IoctlSetPointerInt(p.internal.handle, unix.TIOCMSET, status); err != nil {
return newPortOSError(err)
}
return nil
Expand Down

0 comments on commit bbd0159

Please sign in to comment.