Skip to content
Snippets Groups Projects
Commit dcf1e35b authored by Lev Walkin's avatar Lev Walkin
Browse files

unused bits

parent 53827fd8
No related branches found
No related tags found
No related merge requests found
......@@ -505,7 +505,7 @@ emit_size_determination_code(arg_t *arg, asn1p_expr_type_e etype) {
case ASN_BASIC_BIT_STRING:
OUT("if(st->size > 0) {\n");
OUT("\t/* Size in bits */\n");
OUT("\tsize = 8 * (st->size - 1) - (st->buf[0] & 0x7);\n");
OUT("\tsize = 8 * st->size - (st->bits_unused & 0x07);\n");
OUT("} else {\n");
OUT("\tsize = 0;\n");
OUT("}\n");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment