Write an optional confidential nonce to the 'dst' frame, advancing the cursor 259 cells. * * Precondition: '*dst' is a valid write frame for 259 more cells; * NULL != nonce; */
| 68 | * NULL != nonce; |
| 69 | */ |
| 70 | static void nonce(frameItem* dst, const confidential* nonce) { |
| 71 | if (writeBit(dst, NONE != nonce->prefix)) { |
| 72 | if (writeBit(dst, EXPLICIT == nonce->prefix)) { |
| 73 | skipBits(dst, 1); |
| 74 | } else { |
| 75 | writeBit(dst, ODD_Y == nonce->prefix); |
| 76 | } |
| 77 | writeHash(dst, &nonce->data); |
| 78 | } else { |
| 79 | skipBits(dst, 1+1+256); |
| 80 | } |
| 81 | } |
| 82 | |
| 83 | /* Write an optional 'blindingNonce' from an 'assetIssuance' to the 'dst' frame, advancing the cursor 257 cells. |
| 84 | * |
no test coverage detected