src: remove dead code in AddFingerprintDigest

This function is never called with md_size == 0, and it would make no
sense to do so in the future either.

PR-URL: https://github.com/nodejs/node/pull/42145
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Darshan Sen <raisinten@gmail.com>
This commit is contained in:
Tobias Nießen
2022-03-01 17:21:18 +01:00
committed by GitHub
parent a9c0689786
commit ef30a226ce

View File

@@ -431,11 +431,8 @@ void AddFingerprintDigest(
fingerprint[(3*i)+2] = ':';
}
if (md_size > 0) {
fingerprint[(3*(md_size-1))+2] = '\0';
} else {
fingerprint[0] = '\0';
}
DCHECK_GT(md_size, 0);
fingerprint[(3 * (md_size - 1)) + 2] = '\0';
}
template <const char* (*nid2string)(int nid)>