diff options
Diffstat (limited to 'mcs/class/corlib/System/Byte.cs')
-rw-r--r-- | mcs/class/corlib/System/Byte.cs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/mcs/class/corlib/System/Byte.cs b/mcs/class/corlib/System/Byte.cs index ca35c33af54..41a5b2e1ec3 100644 --- a/mcs/class/corlib/System/Byte.cs +++ b/mcs/class/corlib/System/Byte.cs @@ -157,7 +157,8 @@ namespace System { NumberFormatInfo nfi = NumberFormatInfo.GetInstance (provider); - if (format == null) + // null or empty ("") + if ((format == null) || (format.Length == 0)) format = "G"; return IntegerFormatter.NumberToString (format, nfi, m_value); |