Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/wolfpld/tracy.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKais <kais@kaiscode.com>2020-08-07 05:42:03 +0300
committerKais <kais@kaiscode.com>2020-08-07 05:42:03 +0300
commit83bc1466cffca45f0f232095cc338b917ba2f3ad (patch)
tree467409d8fb9f1cb346660183f6caff4642f03736 /import-chrome
parent550e05d14902a110c57e31186eca745dcb9a886a (diff)
Fix timestamp calculation in chrome tracing importer
Diffstat (limited to 'import-chrome')
-rw-r--r--import-chrome/src/import-chrome.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/import-chrome/src/import-chrome.cpp b/import-chrome/src/import-chrome.cpp
index c5d21172..a5186e4d 100644
--- a/import-chrome/src/import-chrome.cpp
+++ b/import-chrome/src/import-chrome.cpp
@@ -105,7 +105,7 @@ int main( int argc, char** argv )
{
const auto tid = v["tid"].get<uint64_t>();
const auto ts0 = uint64_t( v["ts"].get<double>() * 1000. );
- const auto ts1 = v["dur"].is_object() ? ts0 + uint64_t( v["dur"].get<double>() * 1000. ) : ts0;
+ const auto ts1 = ts0 + uint64_t( v["dur"].get<double>() * 1000. );
const auto name = v["name"].get<std::string>();
timeline.emplace_back( tracy::Worker::ImportEventTimeline { tid, ts0, name, std::move(zoneText), false } );
timeline.emplace_back( tracy::Worker::ImportEventTimeline { tid, ts1, "", "", true } );