crypto: zero is not an error if writing 0 bytes

fix #5128