2019-01-19 01:40:42 +01:00
|
|
|
/*
|
2020-02-22 09:28:27 +01:00
|
|
|
* Copyright (C) 2019-2020 Intel Corporation
|
2019-01-19 01:40:42 +01:00
|
|
|
*
|
|
|
|
|
* SPDX-License-Identifier: MIT
|
|
|
|
|
*
|
|
|
|
|
*/
|
|
|
|
|
|
2020-03-10 10:02:43 +01:00
|
|
|
#include "shared/source/os_interface/windows/environment_variables.h"
|
2019-01-19 01:40:42 +01:00
|
|
|
|
2020-02-23 22:44:01 +01:00
|
|
|
#include "shared/source/debug_settings/debug_settings_manager.h"
|
2019-01-19 01:40:42 +01:00
|
|
|
|
|
|
|
|
#include <Windows.h>
|
|
|
|
|
|
|
|
|
|
uint32_t getEnvironmentVariable(const char *name, char *outBuffer, uint32_t outBufferSize) {
|
2019-03-26 11:59:46 +01:00
|
|
|
if (NEO::DebugManager.registryReadAvailable() == false) {
|
2019-01-19 01:40:42 +01:00
|
|
|
return 0;
|
|
|
|
|
}
|
|
|
|
|
return GetEnvironmentVariableA(name, outBuffer, outBufferSize);
|
|
|
|
|
}
|