mirror of
https://projects.vdr-developer.org/git/vdr-plugin-streamdev.git
synced 2023-10-10 19:16:51 +02:00
Fixed memory leak in buffer overflow situation (thanks to rofafor)
This commit is contained in:
parent
8378d5a17c
commit
7fdf0c6832
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* $Id: connection.c,v 1.8 2007/01/15 12:00:19 schmirl Exp $
|
||||
* $Id: connection.c,v 1.9 2007/05/07 11:43:23 schmirl Exp $
|
||||
*/
|
||||
|
||||
#include "server/connection.h"
|
||||
@ -104,6 +104,7 @@ bool cServerConnection::Respond(const char *Message, bool Last, ...)
|
||||
if (m_WriteBytes + length + 2 > sizeof(m_WriteBuffer)) {
|
||||
esyslog("ERROR: streamdev: output buffer overflow (%s) for %s:%d",
|
||||
m_Protocol, RemoteIp().c_str(), RemotePort());
|
||||
free(buffer);
|
||||
return false;
|
||||
}
|
||||
Dprintf("OUT: |%s|\n", buffer);
|
||||
|
Loading…
Reference in New Issue
Block a user