[Mono.Profiler.Log] Use null references to indicate the absence of names.
authorAlex Rønne Petersen <alpeters@microsoft.com>
Wed, 20 Sep 2017 12:33:46 +0000 (14:33 +0200)
committerAlex Rønne Petersen <alpeters@microsoft.com>
Wed, 20 Sep 2017 12:33:46 +0000 (14:33 +0200)
mcs/class/Mono.Profiler.Log/Mono.Profiler.Log/LogProcessor.cs

index 7e9871efa63034dda37fcfb542604b4b393d9a63..d40897c3a7e60a8e1a8307a09b6f90b4755b68b9 100644 (file)
@@ -474,7 +474,7 @@ namespace Mono.Profiler.Log {
 
                                                list [i] = new CounterDescriptionsEvent.CounterDescription {
                                                        Section = section,
-                                                       SectionName = section == LogCounterSection.User ? _reader.ReadCString () : string.Empty,
+                                                       SectionName = section == LogCounterSection.User ? _reader.ReadCString () : null,
                                                        CounterName = _reader.ReadCString (),
                                                        Type = (LogCounterType) _reader.ReadByte (),
                                                        Unit = (LogCounterUnit) _reader.ReadByte (),
@@ -548,7 +548,7 @@ namespace Mono.Profiler.Log {
                                                Type = helperType,
                                                BufferPointer = ReadPointer (),
                                                BufferSize = (long) _reader.ReadULeb128 (),
-                                               Name = helperType == LogJitHelper.SpecificTrampoline ? _reader.ReadCString () : string.Empty,
+                                               Name = helperType == LogJitHelper.SpecificTrampoline ? _reader.ReadCString () : null,
                                        };
                                        break;
                                }