Quellcode durchsuchen

Make Snapshot Synchronous

JDierkse vor 5 Jahren
Ursprung
Commit
a161173dec
3 geänderte Dateien mit 3 neuen und 3 gelöschten Zeilen
  1. 1 1
      Recorder/FoscamRecorder.cpp
  2. 1 1
      Recorder/VStarCamRecorder.cpp
  3. 1 1
      Recorder/WatchBotRecorder.cpp

+ 1 - 1
Recorder/FoscamRecorder.cpp

@@ -31,7 +31,7 @@ std::string FoscamRecorder::Snapshot(ctpl::thread_pool* pThreadPool)
 
 	Http::HttpClient* pHttpClient = m_pHttpClient;
 	Settings settings = m_settings;
-	pThreadPool->push( [pHttpClient, settings, dateTimeString](int) { FoscamRecorder::Snapshots(pHttpClient, settings, dateTimeString, 1); } );
+	FoscamRecorder::Snapshots(pHttpClient, settings, dateTimeString, 1);
 
 	return fileName;
 }

+ 1 - 1
Recorder/VStarCamRecorder.cpp

@@ -28,7 +28,7 @@ std::string VStarCamRecorder::Snapshot(ctpl::thread_pool* pThreadPool)
 
 	Http::HttpClient* pHttpClient = m_pHttpClient;
 	Settings settings = m_settings;
-	pThreadPool->push( [pHttpClient, settings, dateTimeString](int) { VStarCamRecorder::Snapshots(pHttpClient, settings, dateTimeString, 1); } );
+	VStarCamRecorder::Snapshots(pHttpClient, settings, dateTimeString, 1);
 
 	return fileName;
 }

+ 1 - 1
Recorder/WatchBotRecorder.cpp

@@ -31,7 +31,7 @@ std::string WatchBotRecorder::Snapshot(ctpl::thread_pool* pThreadPool)
 
 	Http::HttpClient* pHttpClient = m_pHttpClient;
 	Settings settings = m_settings;
-	pThreadPool->push( [pHttpClient, settings, dateTimeString](int) { WatchBotRecorder::Snapshots(pHttpClient, settings, dateTimeString, 1); } );
+	WatchBotRecorder::Snapshots(pHttpClient, settings, dateTimeString, 1);
 
 	return fileName;
 }