1
0
Fork 0
management/front/dkha-web-sz-main/node_modules/buffer-xor/index.js

11 lines
206 B
JavaScript
Raw Permalink Normal View History

2023-12-18 13:12:25 +08:00
module.exports = function xor (a, b) {
var length = Math.min(a.length, b.length)
var buffer = new Buffer(length)
for (var i = 0; i < length; ++i) {
buffer[i] = a[i] ^ b[i]
}
return buffer
}