Commit 9e12f2ea authored by Lev Walkin's avatar Lev Walkin

compiler compatibility

parent f7a6c6d4
......@@ -107,7 +107,7 @@ ber_check_tags(asn1_TYPE_descriptor_t *td, ber_dec_ctx_t *ctx,
"len %ld, tag %s",
ptr, (long)size,
size?*(uint8_t *)ptr:0,
(tag_len<size&&tag_len>0)
((size_t)tag_len<size&&tag_len>0)
?*((uint8_t *)ptr + tag_len):0,
(long)tag_len,
ber_tlv_tag_string(tlv_tag));
......
......@@ -201,6 +201,10 @@ SET_decode_ber(asn1_TYPE_descriptor_t *sd,
/* Fall through */
case -1: RETURN(RC_FAIL);
}
printf("size = %ld, ctx->left = %ld\n",
(long)size, (long)ctx->left);
printf("tag_len = %ld, LEFT = %d, %ld\n",
(long)tag_len, LEFT, (long)tlv_tag);
if(ctx->left < 0 && ((uint8_t *)ptr)[0] == 0) {
if(LEFT < 2) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment