mirror of
https://github.com/aseprite/aseprite.git
synced 2025-02-06 03:39:51 +00:00
Fix warning by ThreadSanitizer in HttpLoader
This commit is contained in:
parent
6ce205e0db
commit
93dcc0349f
2
laf
2
laf
@ -1 +1 @@
|
||||
Subproject commit 2d71ca692a60f50312b07f0521a0ffb5c3c9e32f
|
||||
Subproject commit 68a44741998e5a769a9b952ddb422e993dc5b6a9
|
@ -1,5 +1,5 @@
|
||||
// Aseprite
|
||||
// Copyright (C) 2020 Igara Studio S.A.
|
||||
// Copyright (C) 2020-2022 Igara Studio S.A.
|
||||
// Copyright (C) 2001-2016 David Capello
|
||||
//
|
||||
// This program is distributed under the terms of
|
||||
@ -46,7 +46,7 @@ void HttpLoader::abort()
|
||||
void HttpLoader::threadHttpRequest()
|
||||
{
|
||||
try {
|
||||
base::ScopedValue<bool> scoped(m_done, false, true);
|
||||
base::ScopedValue<std::atomic<bool>, bool> scoped(m_done, false, true);
|
||||
|
||||
LOG("HTTP: Sending http request to %s\n", m_url.c_str());
|
||||
|
||||
|
@ -1,4 +1,5 @@
|
||||
// Aseprite
|
||||
// Copyright (C) 2022 Igara Studio S.A.
|
||||
// Copyright (C) 2001-2016 David Capello
|
||||
//
|
||||
// This program is distributed under the terms of
|
||||
@ -9,6 +10,8 @@
|
||||
#pragma once
|
||||
|
||||
#include "base/thread.h"
|
||||
|
||||
#include <atomic>
|
||||
#include <string>
|
||||
|
||||
namespace net {
|
||||
@ -30,7 +33,7 @@ namespace app {
|
||||
void threadHttpRequest();
|
||||
|
||||
std::string m_url;
|
||||
bool m_done;
|
||||
std::atomic<bool> m_done;
|
||||
net::HttpRequest* m_request;
|
||||
base::thread m_thread;
|
||||
std::string m_filename;
|
||||
|
Loading…
x
Reference in New Issue
Block a user