Review Request 120096: replace static arrays with dynamic size with QVector

Milian Wolff mail at milianw.de
Tue Sep 9 20:09:45 UTC 2014


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/120096/#review66153
-----------------------------------------------------------



src/k7zip.cpp
<https://git.reviewboard.kde.org/r/120096/#comment46162>

    You could add a TODO comment to eventually do this. Or do it direclty. It's a good idea. But keep in mind that you'll need to change the code a bit, something like
    
        QByteArray encodedBuffer;
        encodedBuffer.resize(128);
        for (...) {
            const int size = ...;
            if (size > encodedBuffer.size()) {
                encodedBuffer.resize(size);
            }
            ...
        }
    
    :)


- Milian Wolff


On Sept. 9, 2014, 10:19 a.m., Patrick Spendrin wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/120096/
> -----------------------------------------------------------
> 
> (Updated Sept. 9, 2014, 10:19 a.m.)
> 
> 
> Review request for KDE Frameworks and David Faure.
> 
> 
> Repository: karchive
> 
> 
> Description
> -------
> 
> on windows static arrays can only be initialized with a const
> 
> 
> Diffs
> -----
> 
>   src/k7zip.cpp 2db043520ebff6bf7661e8ac993d107f4bd6a5e7 
> 
> Diff: https://git.reviewboard.kde.org/r/120096/diff/
> 
> 
> Testing
> -------
> 
> windows
> 
> 
> Thanks,
> 
> Patrick Spendrin
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20140909/e704947a/attachment-0001.html>


More information about the Kde-frameworks-devel mailing list