question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[BUG]closeableObject could be closed unsafely in MultiplexProducer.Multiplexer#onNextResult

See original GitHub issue

closeableObject could be closed unsafely in MultiplexProducer.Multiplexer#onNextResult

com.facebook.imagepipeline.producers.MultiplexProducer.Multiplexer#onNextResult

      while (iterator.hasNext()) {
        Pair<Consumer<T>, ProducerContext> pair = iterator.next();
        synchronized (pair) {
          pair.first.onNewResult(closeableObject, isFinal);
        }
      }

The Failed Situation is submitting two image request for the same url image, but their width/height is different. In result, one image request is successful, one image request is failed. e.g. image

Here, closeableObject should be cloneOrNull(closeableObject).

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
huangjunkuncommented, Dec 30, 2016

@oprisnik Using version 1.0.0 do not have the issues.

0reactions
oprisnikcommented, Dec 30, 2016

Good to know, thanks @huangjunkun

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to implement multi-producer multi-consumer single-buffer ...
The following multiple producer multiple consumer single buffer implementation is implemented using Ada. The protected object is the buffer.
Read more >
One Producer multiple Consumers - using BlockingQueue
Where a producer will produce items in a commonplace like a Queue. And there are multiple consumers which are processing these records one...
Read more >
Multiple producer-multiple consumer queue, Semaphore
... try restarting your device. Your browser can 't play this video. ... Lecture 25: Multiple producer - multiple consumer queue, Semaphore.
Read more >
8.3. Producer-Consumer Problem
If there are multiple producers trying to enqueue() data, the mutex ensures that they will not try to manipulate the queue at that...
Read more >
L25
However, if there are multiple producers or multiple consumers, this code fails. For example, if two producers try to produce to a full...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found