Skip to content
This repository has been archived by the owner on Feb 25, 2025. It is now read-only.

Commit

Permalink
Fix bug where native image decoders aren't working in release mode
Browse files Browse the repository at this point in the history
  • Loading branch information
bdero committed Oct 20, 2021
1 parent faa45f4 commit 68e2b9d
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions lib/ui/painting/image_generator_registry.cc
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@

#include <algorithm>

#include "flutter/fml/trace_event.h"
#include "flutter/lib/ui/painting/image_generator_registry.h"
#include "third_party/skia/include/codec/SkCodec.h"
#include "third_party/skia/include/core/SkImageGenerator.h"
Expand Down Expand Up @@ -48,8 +47,8 @@ ImageGeneratorRegistry::~ImageGeneratorRegistry() = default;

void ImageGeneratorRegistry::AddFactory(ImageGeneratorFactory factory,
int32_t priority) {
image_generator_factories_.insert(
{factory, priority, fml::tracing::TraceNonce()});
static std::atomic_size_t nonce;
image_generator_factories_.insert({factory, priority, ++nonce});
}

std::shared_ptr<ImageGenerator>
Expand Down

0 comments on commit 68e2b9d

Please sign in to comment.