Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug in reception_flow.cc #214

Open
wowaser opened this issue Mar 13, 2024 · 3 comments
Open

bug in reception_flow.cc #214

wowaser opened this issue Mar 13, 2024 · 3 comments
Labels
bug Something isn't working

Comments

@wowaser
Copy link
Contributor

wowaser commented Mar 13, 2024

Hello,

I have encountered a read access violation while re-initializing my object that holds the uvgrtp functionality. Here's my debugger view:
image

As you can see handlers has been invalidated. I suspect that some other thread calls reception_flow::clear_stream_from_flow which erases from packet_handlers, thus invalidating the pointer. There is no mutex protecting from such occurrence, only a check if (handlers != nullptr), but there is no protection from invalidation after that check.

Unfortunately I don't have a reliable way to reproduce this issue. Hopefully the info I provided is enough :)

Thanks!

@tampsa
Copy link
Collaborator

tampsa commented Mar 28, 2024

Hello,

Sorry to hear that you are experiencing this issue. Some more information on the situation would make it easier for us to debug this. Do you have several sessions inside the uvgRTP context, or several media streams inside the session? Are you deleting and re-creating the context, session or media stream? A description of the situation or code that triggers this bug would be helpful.

-Heikki

@tampsa tampsa added the bug Something isn't working label Mar 28, 2024
@wowaser
Copy link
Contributor Author

wowaser commented Mar 28, 2024

Hello,

I have 1 session with multiple streams. When I re-create my object, I call destroy_session(my_session) and the context just goes out of scope. I want to clarify, that this error does not happen every time I delete my object.

@jrsnen
Copy link
Member

jrsnen commented Apr 3, 2024

Hi,

@wowaser is it so that you continue sending and at the same time you close the session? I'm guessing we haven't tested this scenario much, and there is a moment when the receiver is in an invalid state.

This bug seems something that should be fixed at some point when either me or @tampsa has the time.

BR, Joni

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants