Internet Connect in Mac OS X clobbers other software that uses modem
Internet Connect in Mac OS X clobbers other software that uses modem
- Subject: Internet Connect in Mac OS X clobbers other software that uses modem
- From: Adam Skwersky <email@hidden>
- Date: Sat, 02 Feb 2002 17:47:46 -0500
Hi,
I am the developer of SoftTTY (TTY for the Mac, www.softtty.com). It uses
the modem to emulate a TTY/TDD. In Mac OS Classic, there is a sort of serial
arbitration - only one app can a given serial port at any one time. The
toolbox enforces this by returning an error when a second app tries to open
the serial port.
In Mac OS X, there does not seem to be any one app/one serial port enforcing
going on. I open the app using
open(MachDriverPaths[itsCurrentSerialNum],
O_RDWR | O_NOCTTY | O_NDELAY);
Then, while my app is writing/reading from serial port, I open up Internet
Connect and tell it to "connect" using the same serial port. I would expect
it to come back and say "serial port is already in use", but instead it goes
ahead and tries to open the serial port. In my own app, I start seeing error
-35 (no-access, or "busy").
How do I make sure no other app or process accesses a serial port while I'm
using it?
Adam
--