Skip to content
This repository was archived by the owner on Mar 26, 2023. It is now read-only.

crashing when connect and disconnect button is clicked for many times even with some timegap #64

Open
bhagyalakshmikad opened this issue Oct 8, 2014 · 7 comments

Comments

@bhagyalakshmikad
Copy link

Hi,

  1. If we click connect and disconnect for many times even with some timegap,
    crash occurs at if((m_streamSession->status() & kStreamStatusWriteBufferHasSpace) && m_streamOutRemainder.size()) line in RTMPSession.cpp.

And also waiting for long time after connect button is clicked and if disconnecting
crash occurs at if((m_streamSession->status() & kStreamStatusWriteBufferHasSpace) && m_streamOutRemainder.size()) line.

  1. Sometimes crash occurs at memcpy(p, &zero, sizeof(uint32_t)) in RTMPSession.cpp

Please suggest me with the solution to resolve this.
Thanks in advance.

@skmp
Copy link

skmp commented Oct 10, 2014

I was debugging this yesterday, the issue is that the socket loop runs
after the session is deleted (m_ending is true). I'll see if i can fix and
pr today.

@bhagyalakshmikad
Copy link
Author

Thanks for the reply. Can I know which committed version code that you are working on? Because in recent version code, I didn't find any line related to m_ending is true. But in the old version , I have seen this line.

@skmp
Copy link

skmp commented Oct 10, 2014

m_ending is set in RTMPSession::~RTMPSession()

I think that changing

while((m_streamSession->status() & kStreamStatusReadBufferHasBytes) && !stop2)

to

while(!m_ending && m_streamSession && (m_streamSession->status() & kStreamStatusReadBufferHasBytes) && !stop2)

in line 335

Should fix this issue temporary (but is not a proper fix)

@bhagyalakshmikad
Copy link
Author

Hi, Thanks for the response. I have tested with the modification in line 335. But still the problem is there. Still the crash is occurring by repeatedly pressing connect and disconnect buttons.

@IOSDeveloperProgrammer
Copy link

IOSDeveloperProgrammer commented Aug 13, 2016

@bhagyalakshmikad @skmp Hi,i am having same problem . the crash is occurring by repeatedly pressing disconnect button. Did you find any solution ? Please tell me

@artFintch
Copy link

Hey! Probably I fixed this issue #348

@IOSDeveloperProgrammer
Copy link

@artFintch Hi, I am using videocore version 0.3.2.(red5 server). Working fine but when i was calling [vcsimplesession endrtmpsession], then app is freezing some time.

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

4 participants