From c49ca376bf2554ba71d43c1aa52ddb88bda967ff Mon Sep 17 00:00:00 2001 From: Hyunjin Song Date: Mon, 30 Nov 2020 16:48:26 +0900 Subject: [PATCH] Fix crash on OGG export with Qt >= 5.10 (#5813) --- src/core/audio/AudioFileOgg.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/audio/AudioFileOgg.cpp b/src/core/audio/AudioFileOgg.cpp index ce506f2e1..7e1cb48b4 100644 --- a/src/core/audio/AudioFileOgg.cpp +++ b/src/core/audio/AudioFileOgg.cpp @@ -139,7 +139,7 @@ bool AudioFileOgg::startEncoding() // We give our ogg file a random serial number and avoid // 0 and UINT32_MAX which can get you into trouble. #if (QT_VERSION >= QT_VERSION_CHECK(5,10,0)) - QRandomGenerator::global()->seed(time(0)); + // QRandomGenerator::global() is already initialized, and we can't seed() it. m_serialNo = 0xD0000000 + QRandomGenerator::global()->generate() % 0x0FFFFFFF; #else qsrand(time(0));