Android adaptations
This commit is contained in:
@@ -45,7 +45,7 @@ static int setBasePathInCluster(char **pBasePath)
|
||||
{
|
||||
static char fname[] = "setBasePathInCluster()";
|
||||
|
||||
#ifndef _WIN32
|
||||
#ifdef __linux
|
||||
const char *service_host_env = secure_getenv(SERVICE_HOST_ENV_NAME);
|
||||
#else
|
||||
const char *service_host_env = getenv(SERVICE_HOST_ENV_NAME);
|
||||
@@ -54,7 +54,7 @@ static int setBasePathInCluster(char **pBasePath)
|
||||
fprintf(stderr, "%s: Cannot retrieve the kubernetes service host inside a pod by the env %s.\n", fname, SERVICE_HOST_ENV_NAME);
|
||||
return -1;
|
||||
}
|
||||
#ifndef _WIN32
|
||||
#ifdef __linux
|
||||
const char *service_port_env = secure_getenv(SERVICE_PORT_ENV_NAME);
|
||||
#else
|
||||
const char *service_port_env = getenv(SERVICE_PORT_ENV_NAME);
|
||||
|
||||
@@ -110,7 +110,7 @@ static char *getWorkingConfigFile(const char *configFileNamePassedIn)
|
||||
if (configFileNamePassedIn) {
|
||||
configFileName = strdup(configFileNamePassedIn);
|
||||
} else {
|
||||
#ifndef _WIN32
|
||||
#ifdef __linux
|
||||
kubeconfig_env = secure_getenv(ENV_KUBECONFIG);
|
||||
#else
|
||||
kubeconfig_env = getenv(ENV_KUBECONFIG);
|
||||
@@ -118,7 +118,7 @@ static char *getWorkingConfigFile(const char *configFileNamePassedIn)
|
||||
if (kubeconfig_env) {
|
||||
configFileName = strdup(kubeconfig_env);
|
||||
} else {
|
||||
#ifndef _WIN32
|
||||
#ifdef __linux
|
||||
homedir_env = secure_getenv(ENV_HOME);
|
||||
#else
|
||||
homedir_env = getenv(ENV_HOME);
|
||||
|
||||
Reference in New Issue
Block a user