Abstract FIRSTNBITS(), fix logic

This commit is contained in:
Andrew
2023-06-04 15:06:51 +03:00
parent 08ec7cb9bb
commit 9302ebd751
2 changed files with 9 additions and 7 deletions

View File

@@ -39,6 +39,8 @@
#define FIELD_BITS_2003 512
#define FIELD_BYTES_2003 64
#define FIRSTNBITS(field, n) ((field) & ((1ULL << (n)) - 1))
// Confirmation ID generator constants
#define SUCCESS 0
#define ERR_TOO_SHORT 1