Skip to content

Commit

Permalink
windows pthread_t is uncooperative, just check this instead
Browse files Browse the repository at this point in the history
  • Loading branch information
jacob1 committed Jun 11, 2016
1 parent 5b5390f commit 7e4924e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/client/DownloadManager.cpp
Expand Up @@ -38,7 +38,7 @@ void DownloadManager::Shutdown()
managerShutdown = true;
pthread_mutex_unlock(&downloadAddLock);
pthread_mutex_unlock(&downloadLock);
if (downloadThread != 0)
if (threadStarted)
pthread_join(downloadThread, NULL);
}

Expand Down
2 changes: 1 addition & 1 deletion src/client/HTTP.cpp
Expand Up @@ -946,7 +946,7 @@ std::string FindBoundary(std::map<std::string, std::string> parts, std::string b
for (std::map<std::string, std::string>::iterator iter = parts.begin(); iter != parts.end(); iter++)
{
// loop through every character in each part and search for the substring, adding 1 to map for every character found (character after the substring)
for (ssize_t j = 0; j < (ssize_t)((*iter).second.length())-blen; j++)
for (ssize_t j = 0; j < (ssize_t)((*iter).second.length()-blen); j++)
if (!blen || (*iter).second.substr(j, blen) == boundary)
{
unsigned char ch = (*iter).second[j+blen];
Expand Down

0 comments on commit 7e4924e

Please sign in to comment.