Skip to content

Commit

Permalink
improve country stat logging
Browse files Browse the repository at this point in the history
  • Loading branch information
zachmann committed Aug 26, 2024
1 parent 13aa88f commit 838aa7e
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/oidc-agent/stats/statid.c
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,12 @@ struct statid getStatID() {
.os_info = getOSInfo(),
};
if (getAgentConfig()->stats_collect_location) {
id->location = getLocation();
char* location = getLocation();
if (strValid(location) && !strequal(location, " ")) {
id->location = location;
} else {
secFree(location);
}
}
#ifndef ANY_MSYS
secFree(b);
Expand Down

0 comments on commit 838aa7e

Please sign in to comment.