return ret;
}
-/*-
+/*
* This converts a big endian buffer and sign into its content encoding.
* This is used for INTEGER and ENUMERATED types.
* The internal representation is an ASN1_STRING whose data is a big endian
return 0;
if (neg) {
if (r <= INT64_MAX) {
- /* Most significant bit is guaranteed to be clear, negation
- * is guaranteed to be meaningful in platform-neutral sense. */
+ /*
+ * Most significant bit is guaranteed to be clear, negation
+ * is guaranteed to be meaningful in platform-neutral sense.
+ */
*pr = -(int64_t)r;
} else if (r == ABS_INT64_MIN) {
- /* This never happens if INT64_MAX == ABS_INT64_MIN, e.g.
- * on ones' complement system. */
+ /*
+ * This never happens if INT64_MAX == ABS_INT64_MIN, e.g.
+ * on ones'-complement system.
+ */
*pr = (int64_t)(0 - r);
} else {
ERR_raise(ERR_LIB_ASN1, ASN1_R_TOO_SMALL);
a->type = itype;
if (r < 0) {
- /* Most obvious '-r' triggers undefined behaviour for most
+ /*
+ * Most obvious '-r' triggers undefined behaviour for most
* common INT64_MIN. Even though below '0 - (uint64_t)r' can
- * appear two's complement centric, it does produce correct/
+ * appear two's-complement centric, it does produce correct/
* expected result even on ones' complement. This is because
- * cast to unsigned has to change bit pattern... */
+ * cast to unsigned has to change bit pattern...
+ */
off = asn1_put_uint64(tbuf, 0 - (uint64_t)r);
a->type |= V_ASN1_NEG;
} else {
* Doubles |b|, which is 16 bytes representing an element
* of GF(2**128) modulo the irreducible polynomial
* x**128 + x**7 + x**2 + x + 1.
- * Assumes two's complement arithmetic
+ * Assumes two's-complement arithmetic
*/
static ossl_inline void siv128_dbl(SIV_BLOCK *b)
{