Disable cookies
authorpkanavos <pkanavos@gmail.com>
Tue, 11 Dec 2012 15:36:27 +0000 (17:36 +0200)
committerpkanavos <pkanavos@gmail.com>
Tue, 11 Dec 2012 15:36:27 +0000 (17:36 +0200)
trunk/Pithos.Client.WPF/Preferences/LoginView.xaml.cs

index 6ad6bda..e167483 100644 (file)
@@ -3,6 +3,7 @@ using System.Collections.Generic;
 using System.ComponentModel;\r
 using System.Linq;\r
 using System.Linq.Expressions;\r
+using System.Net;\r
 using System.Net.Http;\r
 using System.Reflection;\r
 using System.Text;\r
@@ -80,7 +81,12 @@ namespace Pithos.Client.WPF.Preferences
             IsBusy.IsBusy = true;\r
             LoginBrowser.Visibility = Visibility.Hidden;\r
 \r
-            var client = new HttpClient();\r
+            var client = new HttpClient(new HttpClientHandler\r
+                {\r
+                    AllowAutoRedirect=true,\r
+                    AutomaticDecompression=DecompressionMethods.Deflate|DecompressionMethods.GZip,\r
+                    UseCookies=false\r
+                });\r
             using (var response = await client.GetAsync(url))\r
             {\r
                 var requestUri = response.RequestMessage.RequestUri;\r