summaryrefslogtreecommitdiff
path: root/indra/llcommon/lltrace.h
diff options
context:
space:
mode:
authorRichard Linden <none@none>2012-11-05 16:10:57 -0800
committerRichard Linden <none@none>2012-11-05 16:10:57 -0800
commit0007114cf5a60779319ab8cbd0a23a0d462b8010 (patch)
tree6bfeb603c3c28f89d1d424abb005741bff7b597a /indra/llcommon/lltrace.h
parentf8eaee753174d0cab4e4edcf795f422706d6f302 (diff)
SH-3499 WIP Ensure asset stats output is correct
fixed copy behavior of recordings and accumulator buffers
Diffstat (limited to 'indra/llcommon/lltrace.h')
-rw-r--r--indra/llcommon/lltrace.h15
1 files changed, 9 insertions, 6 deletions
diff --git a/indra/llcommon/lltrace.h b/indra/llcommon/lltrace.h
index 735c45754c..8ad391e6e5 100644
--- a/indra/llcommon/lltrace.h
+++ b/indra/llcommon/lltrace.h
@@ -38,9 +38,9 @@
#include <list>
-#define TOKEN_PASTE_ACTUAL(x, y) x##y
-#define TOKEN_PASTE(x, y) TOKEN_PASTE_ACTUAL(x, y)
-#define RECORD_BLOCK_TIME(block_timer) LLTrace::BlockTimer::Recorder TOKEN_PASTE(block_time_recorder, __COUNTER__)(block_timer);
+#define LL_TOKEN_PASTE_ACTUAL(x, y) x##y
+#define LL_TOKEN_PASTE(x, y) LL_TOKEN_PASTE_ACTUAL(x, y)
+#define LL_RECORD_BLOCK_TIME(block_timer) LLTrace::BlockTimer::Recorder LL_TOKEN_PASTE(block_time_recorder, __COUNTER__)(block_timer);
namespace LLTrace
{
@@ -93,13 +93,16 @@ namespace LLTrace
public:
- // copying an accumulator buffer does not copy the actual contents, but simply initializes the buffer size
- // to be identical to the other buffer
AccumulatorBuffer(const AccumulatorBuffer& other = getDefaultBuffer())
: mStorageSize(other.mStorageSize),
mStorage(new ACCUMULATOR[other.mStorageSize]),
mNextStorageSlot(other.mNextStorageSlot)
- {}
+ {
+ for (S32 i = 0; i < mNextStorageSlot; i++)
+ {
+ mStorage[i] = other.mStorage[i];
+ }
+ }
~AccumulatorBuffer()
{