提交 f5bb771c authored 作者: Thomas Mueller's avatar Thomas Mueller

There is a problem when opening a database file in a timezone that has different…

There is a problem when opening a database file in a timezone that has different daylight saving rules.
上级 e6674c94
......@@ -72,7 +72,7 @@ public class TcpServerThread implements Runnable {
if (minClientVersion < Constants.TCP_PROTOCOL_VERSION_6) {
throw DbException.get(ErrorCode.DRIVER_VERSION_ERROR_2, "" + clientVersion, "" + Constants.TCP_PROTOCOL_VERSION_6);
} else if (minClientVersion > Constants.TCP_PROTOCOL_VERSION_9) {
throw DbException.get(ErrorCode.DRIVER_VERSION_ERROR_2, "" + clientVersion, "" + Constants.TCP_PROTOCOL_VERSION_8);
throw DbException.get(ErrorCode.DRIVER_VERSION_ERROR_2, "" + clientVersion, "" + Constants.TCP_PROTOCOL_VERSION_9);
}
int maxClientVersion = transfer.readInt();
if (maxClientVersion >= Constants.TCP_PROTOCOL_VERSION_9) {
......
......@@ -332,7 +332,7 @@ public class Transfer {
break;
case Value.DATE:
if (version >= Constants.TCP_PROTOCOL_VERSION_9) {
writeLong(DateTimeUtils.getTimeLocal(v.getTimeNoCopy()));
writeLong(DateTimeUtils.getTimeLocal(v.getDateNoCopy()));
} else if (version >= Constants.TCP_PROTOCOL_VERSION_7) {
writeLong(DateTimeUtils.getTimeLocalWithoutDst(v.getDateNoCopy()));
} else {
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论