[k3b] Re: Review Request: Patch for windows build

Michal Malek michalm at jabster.pl
Wed Feb 2 23:06:46 UTC 2011



> On Feb. 1, 2011, 10:46 p.m., Michal Malek wrote:
> > libk3bdevice/k3bdevice_mmc.cpp, line 177
> > <http://git.reviewboard.kde.org/r/100457/diff/1/?file=7897#file7897line177>
> >
> >     Why do you want to allocate this dynamically? You create a memory leak here.
> 
> Patrick Spendrin wrote:
>     You can't have static arrays with variable size with the msvc compiler so you need to have dynamic fields instead; (memory leak shouldn't happen though).

Ah, I've missed that, you're obviously right. Variable-sized static arrays are illegal in C++. I wonder why GCC tolerated it? Anyway, I've changed it a bit: I've used UByteArray to avoid manual allocating & freeing as it's just asking for trouble.


- Michal


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/100457/#review1147
-----------------------------------------------------------


On Feb. 2, 2011, 1:34 a.m., Andrius da Costa Ribas wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/100457/
> -----------------------------------------------------------
> 
> (Updated Feb. 2, 2011, 1:34 a.m.)
> 
> 
> Review request for K3b, Michal Malek and Patrick Spendrin.
> 
> 
> Summary
> -------
> 
> Small patch to fix building on Windows
> 
> 
> Diffs
> -----
> 
>   cmake/modules/FindSamplerate.cmake 9afd66b 
>   libk3b/projects/audiocd/k3baudiocdtrackreader.cpp 83b6a43 
>   libk3b/tools/qprocess/qringbuffer_p.h 4b5ea48 
>   libk3bdevice/k3bdevice_mmc.cpp 4aa8dbf 
>   src/CMakeLists.txt fd630e4 
>   src/k3bemptydiscwaiter.cpp 738f63c 
>   src/projects/k3bencodingconverter.cpp 93d86f5 
> 
> Diff: http://git.reviewboard.kde.org/r/100457/diff
> 
> 
> Testing
> -------
> 
> Tested using MSVC 2008 on a Windows 7 machine.
> (now I'm testing using MSVC 2010).
> 
> 
> Thanks,
> 
> Andrius da Costa
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/k3b/attachments/20110202/0bb9d780/attachment.html>


More information about the k3b mailing list