Make ReadALConfig noexcept in C++
This commit is contained in:
+2
-2
@@ -285,7 +285,7 @@ void LoadConfigFromFile(std::istream &f)
|
||||
|
||||
|
||||
#ifdef _WIN32
|
||||
void ReadALConfig(void)
|
||||
void ReadALConfig(void) noexcept
|
||||
{
|
||||
WCHAR buffer[MAX_PATH];
|
||||
if(SHGetSpecialFolderPathW(nullptr, buffer, CSIDL_APPDATA, FALSE) != FALSE)
|
||||
@@ -321,7 +321,7 @@ void ReadALConfig(void)
|
||||
}
|
||||
}
|
||||
#else
|
||||
void ReadALConfig(void)
|
||||
void ReadALConfig(void) noexcept
|
||||
{
|
||||
const char *str{"/etc/openal/alsoft.conf"};
|
||||
|
||||
|
||||
+4
-1
@@ -2,10 +2,13 @@
|
||||
#define ALCONFIG_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
#define NOEXCEPT noexcept
|
||||
extern "C" {
|
||||
#else
|
||||
#define NOEXCEPT
|
||||
#endif
|
||||
|
||||
void ReadALConfig(void);
|
||||
void ReadALConfig(void) NOEXCEPT;
|
||||
void FreeALConfig(void);
|
||||
|
||||
int ConfigValueExists(const char *devName, const char *blockName, const char *keyName);
|
||||
|
||||
Reference in New Issue
Block a user