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

ThrottleFirstFrame throws NullReferenceException #160

Closed
hsanno opened this issue Aug 8, 2016 · 2 comments
Closed

ThrottleFirstFrame throws NullReferenceException #160

hsanno opened this issue Aug 8, 2016 · 2 comments

Comments

@hsanno
Copy link

hsanno commented Aug 8, 2016

ThrottleFirstFrame throws NullReferenceException when stream sends OnNext immediately.
Could you allocate tick before subscribing?

// ThrottleFirstFrame.Run
public IDisposable Run()
{
    cancelable = new SerialDisposable();
    // if source sends OnNext immediately, tick is null!
    var subscription = parent.source.Subscribe(this);

    tick = new ThrottleFirstFrameTick(this);

    return StableCompositeDisposable.Create(cancelable, subscription);
}
neuecc added a commit that referenced this issue Aug 8, 2016
@neuecc
Copy link
Owner

neuecc commented Aug 8, 2016

Thank you!
Yes, it's bug!

I've fixed it.

@hsanno
Copy link
Author

hsanno commented Aug 8, 2016

Thank you for your prompt support :)

@hsanno hsanno closed this as completed Aug 8, 2016
cloudchui pushed a commit to CloudcadeSF/UniRx that referenced this issue Jul 27, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants