From 9622068c4e18521f483d7283d4e4be95319c5994 Mon Sep 17 00:00:00 2001 From: James South Date: Tue, 11 Feb 2014 10:10:52 +0000 Subject: [PATCH] Fixes #32 Former-commit-id: 2f6f2c0a35e2f93910e7ea61d8717b0672472de4 --- .../NET45/Caching/DiskCache.cs | 7 ++-- src/ImageProcessor.sln | 36 ++++++++++--------- src/TestWebsites/NET4/Test_Website.csproj | 1 + 3 files changed, 25 insertions(+), 19 deletions(-) diff --git a/src/ImageProcessor.Web/NET45/Caching/DiskCache.cs b/src/ImageProcessor.Web/NET45/Caching/DiskCache.cs index e0bf9c7d3..f4281d64e 100644 --- a/src/ImageProcessor.Web/NET45/Caching/DiskCache.cs +++ b/src/ImageProcessor.Web/NET45/Caching/DiskCache.cs @@ -282,8 +282,11 @@ namespace ImageProcessor.Web.Caching private Tuple SetCachedLastWriteTime() { FileInfo cachedFileInfo = new FileInfo(this.CachedPath); - DateTime creationTime = DateTime.MinValue.ToUniversalTime(); - DateTime lastWriteTime = DateTime.MinValue.ToUniversalTime(); + + // DateTime.Min explodes when used east of GMT. + // Use the SqlDateTime.MinValue. + DateTime creationTime = new DateTime(1753, 1, 1); + DateTime lastWriteTime = new DateTime(1753, 1, 1); if (this.isRemote) { diff --git a/src/ImageProcessor.sln b/src/ImageProcessor.sln index 8166b5032..2c2d93d2a 100644 --- a/src/ImageProcessor.sln +++ b/src/ImageProcessor.sln @@ -1,18 +1,27 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 2012 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ImageProcessor", "ImageProcessor\ImageProcessor.csproj", "{3B5DD734-FB7A-487D-8CE6-55E7AF9AEA7E}" -EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ImageProcessor.Tests", "ImageProcessor.Tests\ImageProcessor.Tests.csproj", "{39911A38-CA06-413C-80AA-39EF60CE984F}" -EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Web.Tests", "Web.Test\Web.Tests.csproj", "{23CE0FC0-9E59-4C93-A604-A4A98A6284D1}" -EndProject +# Visual Studio 2013 +VisualStudioVersion = 12.0.30110.0 +MinimumVisualStudioVersion = 10.0.40219.1 Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{C427A497-74DC-49B1-8420-D6E68354F29B}" ProjectSection(SolutionItems) = preProject ImageProcessor.vsmdi = ImageProcessor.vsmdi Local.testsettings = Local.testsettings EndProjectSection EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".nuget", ".nuget", "{1E656CDE-124D-4FAF-837C-0EF1E192D418}" + ProjectSection(SolutionItems) = preProject + .nuget\NuGet.Config = .nuget\NuGet.Config + .nuget\NuGet.exe = .nuget\NuGet.exe + .nuget\NuGet.targets = .nuget\NuGet.targets + EndProjectSection +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ImageProcessor", "ImageProcessor\ImageProcessor.csproj", "{3B5DD734-FB7A-487D-8CE6-55E7AF9AEA7E}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ImageProcessor.Tests", "ImageProcessor.Tests\ImageProcessor.Tests.csproj", "{39911A38-CA06-413C-80AA-39EF60CE984F}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Web.Tests", "Web.Test\Web.Tests.csproj", "{23CE0FC0-9E59-4C93-A604-A4A98A6284D1}" +EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Test_Website", "TestWebsites\NET4\Test_Website.csproj", "{30327C08-7574-4D7E-AC95-6A58753C6855}" EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Test_Website_NET45", "TestWebsites\NET45\Test_Website_NET45\Test_Website_NET45.csproj", "{F6A208E9-C18F-43E9-B051-3C6EED30FDAF}" @@ -21,19 +30,9 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ImageProcessor.Web", "Image EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ImageProcessor.Web_NET45", "ImageProcessor.Web\NET45\ImageProcessor.Web_NET45.csproj", "{D011A778-59C8-4BFA-A770-C350216BF161}" EndProject -Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".nuget", ".nuget", "{1E656CDE-124D-4FAF-837C-0EF1E192D418}" - ProjectSection(SolutionItems) = preProject - .nuget\NuGet.Config = .nuget\NuGet.Config - .nuget\NuGet.exe = .nuget\NuGet.exe - .nuget\NuGet.targets = .nuget\NuGet.targets - EndProjectSection -EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Test_Website_Webforms_NET45", "TestWebsites\NET45\Test_Website_Webforms_NET45\Test_Website_Webforms_NET45.csproj", "{8DA47D8C-DB1A-4D82-843F-896AB9C3B3D2}" EndProject Global - GlobalSection(TestCaseManagementSettings) = postSolution - CategoryFile = ImageProcessor.vsmdi - EndGlobalSection GlobalSection(SolutionConfigurationPlatforms) = preSolution All|Any CPU = All|Any CPU All|Mixed Platforms = All|Mixed Platforms @@ -175,4 +174,7 @@ Global GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection + GlobalSection(TestCaseManagementSettings) = postSolution + CategoryFile = ImageProcessor.vsmdi + EndGlobalSection EndGlobal diff --git a/src/TestWebsites/NET4/Test_Website.csproj b/src/TestWebsites/NET4/Test_Website.csproj index c48be9d56..9e19df7ed 100644 --- a/src/TestWebsites/NET4/Test_Website.csproj +++ b/src/TestWebsites/NET4/Test_Website.csproj @@ -27,6 +27,7 @@ ..\..\ true + true true