omaha: distinguish zero and unset in ping active days field

Unlike the other fields unset here would mean unknown rather than "0" so
we must distinguish between the two. In the end it isn't very
significant since our update server and none of our clients use these
self-reported active times, exclusively using when pings were received.
This commit is contained in:
Michael Marineau 2017-04-24 13:05:53 -07:00
parent c7d81825c4
commit 9a796427d5
1 changed files with 3 additions and 3 deletions

View File

@ -108,9 +108,9 @@ type UpdateRequest struct {
}
type PingRequest struct {
Active int `xml:"active,attr,omitempty"`
LastActiveReportDays int `xml:"a,attr,omitempty"`
LastReportDays int `xml:"r,attr,omitempty"`
Active int `xml:"active,attr,omitempty"`
LastActiveReportDays *int `xml:"a,attr,omitempty"`
LastReportDays int `xml:"r,attr,omitempty"`
}
type EventRequest struct {