[Live-devel] Coverity detected a memory leak in RTSPClient::setupMediaSubsession
Mathew Hounsell
mathew.hounsell at avegasystems.com
Thu May 3 18:50:27 PDT 2007
I thought before I patch this I must get the latest code; and I know I went to
the website. Guess I must have got distracted.
Here is a diff for just that fix.
Mathew Hounsell wrote:
> "sessionStr", "setupStr", "authenticatorStr" are not deleted when the
> function returns ar 1018 because of break at 902
>
> 900 if (rtpNumber == 0) {
> 901 envir().setResultMsg("Client port number unknown\n");
> 902 break;
> 903 }
>
> 1017 delete[] cmd;
> 1018 return False;
> 1019 } // End of Function
>
> While looking at the fix for this I thought it simpler to functionally
> decompose the setup string creation, and go with the old style single
> return point. This does not address the std::bad_alloc exception case.
>
> My patch is attached; svn diff format.
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: liveMedia-RTSPClient-memory-leak.diff
Type: text/x-patch
Size: 448 bytes
Desc: not available
Url : http://lists.live555.com/pipermail/live-devel/attachments/20070503/806ff6d5/attachment-0001.bin
More information about the live-devel
mailing list