Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'mcs/class/System/System.Net/Cookie.cs')
-rw-r--r--mcs/class/System/System.Net/Cookie.cs35
1 files changed, 18 insertions, 17 deletions
diff --git a/mcs/class/System/System.Net/Cookie.cs b/mcs/class/System/System.Net/Cookie.cs
index 30ee979fef1..c0235be1f1e 100644
--- a/mcs/class/System/System.Net/Cookie.cs
+++ b/mcs/class/System/System.Net/Cookie.cs
@@ -57,23 +57,24 @@ namespace System.Net {
private static char [] reservedCharsValue = new char [] {';', ','};
private static char [] portSeparators = new char [] {'"', ','};
private static string tspecials = "()<>@,;:\\\"/[]?={} \t"; // from RFC 2965, 2068
-
- public Cookie ()
- {
- expires = DateTime.MinValue;
- timestamp = DateTime.Now;
- domain = "";
- name = "";
- val = "";
- }
-
- public Cookie (string name, string value)
- : this ()
- {
- Name = name;
- Value = value;
- }
-
+
+ public Cookie ()
+ : this (String.Empty, String.Empty) {}
+
+ public Cookie (string name, string value)
+ {
+ Name = name;
+ Value = value;
+
+ discard = false;
+ expired = false;
+ secure = false;
+ expires = DateTime.MinValue;
+ timestamp = DateTime.Now;
+ version = 0;
+ domain = "";
+ }
+
public Cookie (string name, string value, string path)
: this (name, value)
{