diff options
-rw-r--r-- | lib/connectiondata.cpp | 2 | ||||
-rw-r--r-- | tests/CMakeLists.txt | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/lib/connectiondata.cpp b/lib/connectiondata.cpp index a3807fc4..cbc36420 100644 --- a/lib/connectiondata.cpp +++ b/lib/connectiondata.cpp @@ -67,7 +67,6 @@ ConnectionData::ConnectionData(QUrl baseUrl) for (auto& q : d->jobs) while (!q.empty()) { auto& job = q.front(); - q.pop(); if (!job || job->error() == BaseJob::Abandoned) continue; if (job->error() != BaseJob::Pending) { @@ -79,6 +78,7 @@ ConnectionData::ConnectionData(QUrl baseUrl) } job->sendRequest(); d->rateLimiter.start(); + q.pop(); return; } qCDebug(MAIN) << d->id() << "job queues are empty"; diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index b6ba0f18..490a2506 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -45,11 +45,11 @@ foreach (FLAG all "" pedantic extra error=return-type no-unused-parameter no-gnu endif () endforeach () -find_package(Qt5 5.9 REQUIRED Network Gui Multimedia) +find_package(Qt5 5.9 REQUIRED Network Gui Multimedia Test) get_filename_component(Qt5_Prefix "${Qt5_DIR}/../../../.." ABSOLUTE) find_package(Quotient REQUIRED) -get_filename_component(QMC_Prefix "${Quotient_DIR}/../.." ABSOLUTE) +get_filename_component(Quotient_Prefix "${Quotient_DIR}/../.." ABSOLUTE) message( STATUS "${PROJECT_NAME} configuration:" ) if (CMAKE_BUILD_TYPE) @@ -57,12 +57,12 @@ if (CMAKE_BUILD_TYPE) endif(CMAKE_BUILD_TYPE) message( STATUS " Compiler: ${CMAKE_CXX_COMPILER_ID} ${CMAKE_CXX_COMPILER_VERSION}" ) message( STATUS " Qt: ${Qt5_VERSION} at ${Qt5_Prefix}" ) -message( STATUS " Quotient: ${Quotient_VERSION} at ${QMC_Prefix}" ) +message( STATUS " Quotient: ${Quotient_VERSION} at ${Quotient_Prefix}" ) set(example_SRCS quotest.cpp) add_executable(${PROJECT_NAME} ${example_SRCS}) -target_link_libraries(${PROJECT_NAME} Qt5::Core Quotient) +target_link_libraries(${PROJECT_NAME} Qt5::Core Qt5::Test Quotient) # Installation |