tls: improve debugging assertion

Refs: https://github.com/nodejs/node/issues/22618

PR-URL: https://github.com/nodejs/node/pull/22625
Reviewed-By: Anatoli Papirovski <apapirovski@mac.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
This commit is contained in:
Anna Henningsen 2018-08-31 17:42:54 +02:00
parent f42323109a
commit c0e3af1bf2
No known key found for this signature in database
GPG Key ID: 9C63F3A6CD2AD8F9

View File

@ -64,7 +64,8 @@ function onhandshakestart(now) {
debug('onhandshakestart');
const { lastHandshakeTime } = this;
assert(now >= lastHandshakeTime);
assert(now >= lastHandshakeTime,
`now (${now}) < lastHandshakeTime (${lastHandshakeTime})`);
this.lastHandshakeTime = now;