maxDataSizeDontOutput = 200 * 1024

This commit is contained in:
gazebo
2019-12-18 23:00:22 +08:00
parent d70304cfea
commit c1866ed5c9
2 changed files with 8 additions and 3 deletions

View File

@@ -63,7 +63,7 @@ const (
)
const (
maxDataSizeDontOutput = 50 * 1024
maxDataSizeDontOutput = 200 * 1024
)
// common api access error

View File

@@ -57,13 +57,18 @@ func Pointer2Float64(ptr *float64) (value float64) {
return value
}
func Time2Pointer(value time.Time) *time.Time {
return &value
func Time2Pointer(value time.Time) (valuePtr *time.Time) {
if !IsTimeZero(value) {
valuePtr = &value
}
return valuePtr
}
func Pointer2Time(ptr *time.Time) (value time.Time) {
if ptr != nil {
value = *ptr
} else {
value = DefaultTimeValue
}
return value
}