@ -19,8 +19,8 @@ static u64 GenerateTelemetryId() {
u64 GetTelemetryId ( ) {
u64 GetTelemetryId ( ) {
u64 telemetry_id { } ;
u64 telemetry_id { } ;
static const std : : string & filename { FileUtil : : GetUserPath ( FileUtil : : UserPath : : ConfigDir ) +
const std : : string filename { FileUtil : : GetUserPath ( FileUtil : : UserPath : : ConfigDir ) +
" telemetry_id " } ;
" telemetry_id " } ;
if ( FileUtil : : Exists ( filename ) ) {
if ( FileUtil : : Exists ( filename ) ) {
FileUtil : : IOFile file ( filename , " rb " ) ;
FileUtil : : IOFile file ( filename , " rb " ) ;
@ -44,8 +44,8 @@ u64 GetTelemetryId() {
u64 RegenerateTelemetryId ( ) {
u64 RegenerateTelemetryId ( ) {
const u64 new_telemetry_id { GenerateTelemetryId ( ) } ;
const u64 new_telemetry_id { GenerateTelemetryId ( ) } ;
static const std : : string & filename { FileUtil : : GetUserPath ( FileUtil : : UserPath : : ConfigDir ) +
const std : : string filename { FileUtil : : GetUserPath ( FileUtil : : UserPath : : ConfigDir ) +
" telemetry_id " } ;
" telemetry_id " } ;
FileUtil : : IOFile file ( filename , " wb " ) ;
FileUtil : : IOFile file ( filename , " wb " ) ;
if ( ! file . IsOpen ( ) ) {
if ( ! file . IsOpen ( ) ) {