aboutsummaryrefslogtreecommitdiffstats
path: root/alc/backends/null.cpp
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2020-12-17 21:07:53 -0800
committerChris Robinson <[email protected]>2020-12-17 21:07:53 -0800
commit5edd5a11fc16147ee25566db75732533005d1f46 (patch)
tree7f6e89f7c7afcb150a57b40f8aa5c25baf26c43e /alc/backends/null.cpp
parent7d2e21334c5bc6423abed3b450d369829d7c1fde (diff)
Don't use ALC error enums for the backend error code
Diffstat (limited to 'alc/backends/null.cpp')
-rw-r--r--alc/backends/null.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/alc/backends/null.cpp b/alc/backends/null.cpp
index 8a134a93..dd22a56b 100644
--- a/alc/backends/null.cpp
+++ b/alc/backends/null.cpp
@@ -111,7 +111,8 @@ void NullBackend::open(const ALCchar *name)
if(!name)
name = nullDevice;
else if(strcmp(name, nullDevice) != 0)
- throw al::backend_exception{ALC_INVALID_VALUE, "Device name \"%s\" not found", name};
+ throw al::backend_exception{al::backend_error::NoDevice, "Device name \"%s\" not found",
+ name};
mDevice->DeviceName = name;
}
@@ -129,8 +130,8 @@ void NullBackend::start()
mThread = std::thread{std::mem_fn(&NullBackend::mixerProc), this};
}
catch(std::exception& e) {
- throw al::backend_exception{ALC_INVALID_DEVICE, "Failed to start mixing thread: %s",
- e.what()};
+ throw al::backend_exception{al::backend_error::DeviceError,
+ "Failed to start mixing thread: %s", e.what()};
}
}