Skip to content

Commit

Permalink
Remove Unused ThreadList
Browse files Browse the repository at this point in the history
We kept a list of threads, but never used them. Additionally, we never
even rejoined. Switched to an implementation that detaches our temporary
threads and gets rid of the unused list.
  • Loading branch information
Ozymandias117 committed Dec 5, 2016
1 parent c1b5ea0 commit a2df27b
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/http.cc
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@ namespace blt {
using std::thread;
using std::mutex;

static list<thread*> threadList;

struct HTTPProgressNotification
{
HTTPItem* item;
Expand Down Expand Up @@ -236,7 +234,8 @@ namespace blt {
void
HTTPManager::launch_request(HTTPItem* xfData)
{
threadList.push_back(new thread(launch_http_thread, xfData));
std::thread local_thread(launch_http_thread, xfData);
local_thread.detach();
}


Expand Down

0 comments on commit a2df27b

Please sign in to comment.