Skip to content

Commit

Permalink
Cleanup conditionals for potential future connection type expansion
Browse files Browse the repository at this point in the history
brickOS-bibo supports more connection types
  • Loading branch information
mesheets committed Jul 11, 2024
1 parent 9ff7164 commit ccfbb6d
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions rcxlib/RCX_Link.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -150,8 +150,9 @@ RCX_Result RCX_Link::Open(RCX_TargetType target, const char *portName, ULong opt
gUSB = false;
if (portName) {
// strip off "serial:" prefix if present
devName = CheckPrefix(portName, "serial");
if (!devName) devName = portName;
if ((devName = CheckPrefix(portName, "serial")) != 0) {}
// strip off "com:" prefix if present
else if (!devName) { devName = portName; }
}
else {
devName = PSerial::GetDefaultName();
Expand Down

0 comments on commit ccfbb6d

Please sign in to comment.