1
0
mirror of synced 2025-02-28 22:50:24 +01:00

Look for /dev/dsp and /dev/dsp1

This commit is contained in:
Bobby Dilley 2025-01-28 10:45:35 +00:00
parent 685d569a08
commit 8942c510ec

View File

@ -305,6 +305,15 @@ int open(const char *pathname, int flags, ...)
int (*_open)(const char *pathname, int flags, ...) = dlsym(RTLD_NEXT, "open");
// Attempt to open /dev/dsp1 and /dev/dsp
if (strcmp(pathname, "/dev/dsp") == 0) {
int dspFileDescriptor = _open("/dev/dsp1", flags, mode);
if(dspFileDescriptor != -1)
return dspFileDescriptor;
return _open("/dev/dsp", flags, mode);
}
if (strcmp(pathname, "/dev/lbb") == 0)
{
hooks[BASEBOARD] = _open(HOOK_FILE_NAME, flags, mode);