mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2025-11-07 10:43:58 +00:00
Fix use of auto that caused a copy
This commit is contained in:
@@ -498,7 +498,7 @@ rtklib_pvt_gs::rtklib_pvt_gs(uint32_t nchannels,
|
|||||||
std::ostringstream os;
|
std::ostringstream os;
|
||||||
#ifdef HAS_PUT_TIME
|
#ifdef HAS_PUT_TIME
|
||||||
time_t when = std::time(nullptr);
|
time_t when = std::time(nullptr);
|
||||||
auto const tm = *std::localtime(&when);
|
const auto& tm = *std::localtime(&when);
|
||||||
os << std::put_time(&tm, "%z");
|
os << std::put_time(&tm, "%z");
|
||||||
#endif
|
#endif
|
||||||
std::string utc_diff_str = os.str(); // in ISO 8601 format: "+HHMM" or "-HHMM"
|
std::string utc_diff_str = os.str(); // in ISO 8601 format: "+HHMM" or "-HHMM"
|
||||||
|
|||||||
Reference in New Issue
Block a user