Mailing List archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[vdr] Re: VDR developer version 1.1.22
Stefan Huelswitt wrote:
>
> On 26 Jan 2003 Klaus Schmidinger <Klaus.Schmidinger@cadsoft.de> wrote:
>
> Another thing:
>
> in dvbplayer.c:
>
> b = MALLOC(uchar, Length);
> }
> int r = nonBlockingFileReader->Read(replayFile, b, Length);
> if (r > 0) {
> readFrame = new cFrame(b, -r, ftUnknown, readIndex); // hands over b to the ringBuffer
>
> but in ringbuffer.c:
>
> cFrame::~cFrame()
> {
> delete data;
> }
>
> a new/delete malloc/free mismatch. Right?
You're right, sorry...
This should fix it:
--- ringbuffer.c 2003/01/26 09:39:24 1.12
+++ ringbuffer.c 2003/01/26 19:47:10
@@ -188,7 +188,7 @@
if (Count < 0)
data = (uchar *)Data;
else {
- data = new uchar[count];
+ data = MALLOC(uchar, count);
if (data)
memcpy(data, Data, count);
else
@@ -199,7 +199,7 @@
cFrame::~cFrame()
{
- delete data;
+ free(data);
}
Klaus
--
_______________________________________________________________
Klaus Schmidinger Phone: +49-8635-6989-10
CadSoft Computer GmbH Fax: +49-8635-6989-40
Hofmark 2 Email: kls@cadsoft.de
D-84568 Pleiskirchen, Germany URL: www.cadsoft.de
_______________________________________________________________
--
Info:
To unsubscribe send a mail to listar@linuxtv.org with "unsubscribe vdr" as subject.
Home |
Main Index |
Thread Index