diff options
author | Alex Rønne Petersen <alexrp@xamarin.com> | 2016-09-14 22:14:20 +0300 |
---|---|---|
committer | Alex Rønne Petersen <alexrp@xamarin.com> | 2016-10-02 19:56:17 +0300 |
commit | cf076ebd1dfc8aa912eb3199ef7c8d9eda0b1876 (patch) | |
tree | a320599014cf70b7312d86d6537ec3a5229fc957 | |
parent | d3ff7dca3e8e1f63e3ff88e611cc8b268a50055b (diff) |
[profiler] Address a couple of FIXMEs in the counters sampling code.
-rw-r--r-- | mono/profiler/mono-profiler-log.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/mono/profiler/mono-profiler-log.c b/mono/profiler/mono-profiler-log.c index 64abb62179a..5b901e28754 100644 --- a/mono/profiler/mono-profiler-log.c +++ b/mono/profiler/mono-profiler-log.c @@ -2978,17 +2978,15 @@ counters_sample (MonoProfiler *profiler, uint64_t timestamp) counter = agent->counter; size = mono_counter_get_size (counter); - if (size < 0) { - continue; // FIXME error - } else if (size > buffer_size) { + + if (size > buffer_size) { buffer_size = size; buffer = g_realloc (buffer, buffer_size); } memset (buffer, 0, buffer_size); - if (mono_counters_sample (counter, buffer, size) < 0) - continue; // FIXME error + g_assert (mono_counters_sample (counter, buffer, size)); type = mono_counter_get_type (counter); |