Re: [hatari-devel] SCC issues (vs. real MegaSTE) mentioned in Atari-forum |
[ Thread Index |
Date Index
| More lists.tuxfamily.org/hatari-devel Archives
]
Hi,
On 12.9.2024 11.35, Thomas Huth wrote:
On 10/09/2024 16.38, Nicolas Pomarède wrote:
I'm looking at this to make both code more similar but I see rs232.c
is using File_Open to open the in/out file associated with the serial
port, and not using open() directly as in scc.c
Is there any reason for that ? I see File_Open allows to use stderr
and stdout as a filename but is that really used for rs232 emulation ?
At least on Linux, one could also use open() with /dev/stderr or
/dev/stdout for that.
Does that work also for Mac / BSD?
If not, I'd rather replace use of "FILE *" handler by file descriptor
number (as returned by open() )
Any idea on that ?
I think it's mainly that way since this is based on very old WinSTon
code. Back then, I rather replaced the Windows functions with the
portable fopen() etc. instead of using the low-level functions instead.
....i.e. is File_Open() there just for supporting this niche feature for
Windows?
- Eero