Skip to content

Commit 4996562

Browse files
committed
Merge branch '2.7'
2 parents fd893c2 + a73a89c commit 4996562

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

release-notes/VERSION

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,8 @@ Project: jackson-databind
7272
(reported by brentryan@github)
7373
#1279: Ensure DOM parsing defaults to not expanding external entities
7474
#1288: Type id not exposed for `JsonTypeInfo.As.EXTERNAL_PROPERTY` even when `visible` set to `true`
75+
#1299: Timestamp deserialization error
76+
(reported by liyuj@github)
7577
#1301: Problem with `JavaType.toString()` for recursive (self-referential) types
7678
(reported by Brian P)
7779
#1307: `TypeWrappedDeserializer` doesn't delegate the `getNullValue()` method to `_deserializer`

src/main/java/com/fasterxml/jackson/databind/deser/std/DateDeserializers.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -306,7 +306,8 @@ protected TimestampDeserializer withDateFormat(DateFormat df, String formatStrin
306306
@Override
307307
public java.sql.Timestamp deserialize(JsonParser jp, DeserializationContext ctxt) throws IOException
308308
{
309-
return new Timestamp(_parseDate(jp, ctxt).getTime());
309+
Date d = _parseDate(jp, ctxt);
310+
return (d == null) ? null : new Timestamp(d.getTime());
310311
}
311312
}
312313
}

0 commit comments

Comments
 (0)