Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversion error for DateTime.MinValue or MaxValue #401

Closed
CrazyViper opened this issue Jun 12, 2015 · 1 comment
Closed

Conversion error for DateTime.MinValue or MaxValue #401

CrazyViper opened this issue Jun 12, 2015 · 1 comment
Assignees
Milestone

Comments

@CrazyViper
Copy link
Contributor

Conversion from DateTimeMinValaue to DateTimeOffset fails with ArgumentOutOfRangeException:

The UTC time represented when the offset is applied must be between year 0 and 10,000.

It happens in ODataPrimitiveSerializer on line:

DateTimeOffset dateTimeOffset = new DateTimeOffset(dateTime, timeZone.GetUtcOffset(dateTime));

I assume that min and max values must de converted without timezone.

@xuzhg
Copy link
Member

xuzhg commented Jul 14, 2015

Merged. Thanks.

@xuzhg xuzhg closed this as completed Jul 14, 2015
@xuzhg xuzhg self-assigned this Jul 14, 2015
@xuzhg xuzhg added this to the v5.7 milestone Jul 14, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants