mirror of
https://github.com/GoogleChromeLabs/squoosh.git
synced 2025-11-14 01:37:26 +00:00
Switch vals to thread_locals
It's not possible to share them across threads, so in case we decide to use multithreading in the future, it's best to mark them as thread_local right away, even if it's a no-op right now.
This commit is contained in:
committed by
Ingvar Stepanyan
parent
f1cd6a87da
commit
e342766cbf
@@ -10,8 +10,8 @@ int version() {
|
||||
return WebPGetDecoderVersion();
|
||||
}
|
||||
|
||||
const val Uint8ClampedArray = val::global("Uint8ClampedArray");
|
||||
const val ImageData = val::global("ImageData");
|
||||
thread_local const val Uint8ClampedArray = val::global("Uint8ClampedArray");
|
||||
thread_local const val ImageData = val::global("ImageData");
|
||||
|
||||
val decode(std::string buffer) {
|
||||
int width, height;
|
||||
|
||||
Reference in New Issue
Block a user