@@ -94,7 +94,7 @@ void ChunkReader::load_json()
9494 info.has_video = root[" has_video" ].asBool ();
9595 info.has_audio = root[" has_audio" ].asBool ();
9696 info.duration = root[" duration" ].asDouble ();
97- info.file_size = atoll (root[" file_size" ].asString (). c_str ());
97+ info.file_size = std::stoll (root[" file_size" ].asString ());
9898 info.height = root[" height" ].asInt ();
9999 info.width = root[" width" ].asInt ();
100100 info.pixel_format = root[" pixel_format" ].asInt ();
@@ -106,7 +106,7 @@ void ChunkReader::load_json()
106106 info.display_ratio .num = root[" display_ratio" ][" num" ].asInt ();
107107 info.display_ratio .den = root[" display_ratio" ][" den" ].asInt ();
108108 info.vcodec = root[" vcodec" ].asString ();
109- info.video_length = atoll (root[" video_length" ].asString (). c_str ());
109+ info.video_length = std::stoll (root[" video_length" ].asString ());
110110 info.video_stream_index = root[" video_stream_index" ].asInt ();
111111 info.video_timebase .num = root[" video_timebase" ][" num" ].asInt ();
112112 info.video_timebase .den = root[" video_timebase" ][" den" ].asInt ();
@@ -316,7 +316,7 @@ void ChunkReader::SetJsonValue(Json::Value root) {
316316 if (!root[" path" ].isNull ())
317317 path = root[" path" ].asString ();
318318 if (!root[" chunk_size" ].isNull ())
319- chunk_size = atoll (root[" chunk_size" ].asString (). c_str ());
319+ chunk_size = std::stoll (root[" chunk_size" ].asString ());
320320 if (!root[" chunk_version" ].isNull ())
321321 version = (ChunkVersion) root[" chunk_version" ].asInt ();
322322
0 commit comments