Re: [cmake-developers] [PATCH] Avoid bad alloc for large files

2014-12-23 Thread Rolf Eike Beer
Am Montag, 22. Dezember 2014, 22:16:50 schrieb Rolf Eike Beer: Am Montag, 22. Dezember 2014, 10:50:28 schrieb Brad King: On 12/20/2014 08:44 AM, Rolf Eike Beer wrote: This is basically the same, but it avoids the needless floating point arithmetic. Does it work for you? Thanks, Eike.

Re: [cmake-developers] [PATCH] Avoid bad alloc for large files

2014-12-23 Thread Rolf Eike Beer
Am Dienstag, 23. Dezember 2014, 10:27:47 schrieb Rolf Eike Beer: Am Montag, 22. Dezember 2014, 22:16:50 schrieb Rolf Eike Beer: Am Montag, 22. Dezember 2014, 10:50:28 schrieb Brad King: On 12/20/2014 08:44 AM, Rolf Eike Beer wrote: This is basically the same, but it avoids the needless

Re: [cmake-developers] [PATCH] Avoid bad alloc for large files

2014-12-23 Thread Brad King
On 12/23/2014 4:27 AM, Rolf Eike Beer wrote: cmCTest.cxx C:\Dashboards\My Tests\CMakeNext-vs12-64-ninja-src\Source\cmCTest.cxx(1705) : warning C4267: 'argument' : conversion from 'size_t' to 'unsigned long', possible loss of data The problem is: this is absolutely right. On Windows64 this

Re: [cmake-developers] [PATCH] Avoid bad alloc for large files

2014-12-22 Thread Brad King
On 12/20/2014 08:44 AM, Rolf Eike Beer wrote: This is basically the same, but it avoids the needless floating point arithmetic. Does it work for you? Thanks, Eike. Please add a topic to put this in 'next' when ready. Thanks, -Brad -- Powered by www.kitware.com Please keep messages

Re: [cmake-developers] [PATCH] Avoid bad alloc for large files

2014-12-22 Thread Domen Vrankar
I received a bad alloc when uploading a large file with CTest. The patch below resolved this. Your patch is line-wrapped and can't be applied. However, I did this by hand. This is basically the same, but it avoids the needless floating point arithmetic. Does it work for you? snip

Re: [cmake-developers] [PATCH] Avoid bad alloc for large files

2014-12-22 Thread Domen Vrankar
I received a bad alloc when uploading a large file with CTest. The patch below resolved this. I just took a look at the code and noticed that it is quite memory consumption heavy ((2 * encoded_buffer_size) + file_buffer_size). This implementation could be used instead (not tested): std::string

Re: [cmake-developers] [PATCH] Avoid bad alloc for large files

2014-12-22 Thread Rolf Eike Beer
Am Montag, 22. Dezember 2014, 10:50:28 schrieb Brad King: On 12/20/2014 08:44 AM, Rolf Eike Beer wrote: This is basically the same, but it avoids the needless floating point arithmetic. Does it work for you? Thanks, Eike. Please add a topic to put this in 'next' when ready. Done. I

[cmake-developers] [PATCH] Avoid bad alloc for large files

2014-12-20 Thread Justin Borodinsky
I received a bad alloc when uploading a large file with CTest. The patch below resolved this. --- Source/cmCTest.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Source/cmCTest.cxx b/Source/cmCTest.cxx index 2bf7b77..52bf651 100644 --- a/Source/cmCTest.cxx +++

Re: [cmake-developers] [PATCH] Avoid bad alloc for large files

2014-12-20 Thread Rolf Eike Beer
Justin Borodinsky wrote: I received a bad alloc when uploading a large file with CTest. The patch below resolved this. Your patch is line-wrapped and can't be applied. However, I did this by hand. This is basically the same, but it avoids the needless floating point arithmetic. Does it work for

Re: [cmake-developers] [PATCH] Avoid bad alloc for large files

2014-12-20 Thread Justin Borodinsky
Yes, thank you. On Saturday, December 20, 2014, Rolf Eike Beer e...@sf-mail.de wrote: Justin Borodinsky wrote: I received a bad alloc when uploading a large file with CTest. The patch below resolved this. Your patch is line-wrapped and can't be applied. However, I did this by hand. This