Skip to content

Commit

Permalink
ckp
Browse files Browse the repository at this point in the history
  • Loading branch information
DennisHeimbigner committed Jan 17, 2025
1 parent b6ed1e9 commit 8b48b47
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions libdispatch/drc.c
Original file line number Diff line number Diff line change
Expand Up @@ -137,15 +137,13 @@ This is set by the environment variable NC_TEST_AWS_DIR.
void
ncrc_initialize(void)
{
int stat = NC_NOERR;
NCglobalstate* ncg = NULL;

if(NCRCinitialized) return;
NCRCinitialized = 1; /* prevent recursion */

ncg = NC_getglobalstate();

#ifndef NOREAD
{
int stat = NC_NOERR;
NCglobalstate* ncg = NC_getglobalstate();
/* Load entrys */
if((stat = NC_rcload())) {
nclog(NCLOGWARN,".rc loading failed");
Expand All @@ -154,6 +152,7 @@ ncrc_initialize(void)
if((stat = NC_aws_load_credentials(ncg))) {
nclog(NCLOGWARN,"AWS config file not loaded");
}
}
#endif
}

Expand Down Expand Up @@ -329,7 +328,7 @@ NC_set_rcfile(const char* rcfile)
goto done;
}
fclose(f);
nullfree(globalstate->rcinfo->rcfile);
NC_rcclear(globalstate->rcinfo);
globalstate->rcinfo->rcfile = strdup(rcfile);
/* Clear globalstate->rcinfo */
NC_rcclear(&globalstate->rcinfo);
Expand Down

0 comments on commit 8b48b47

Please sign in to comment.