OpenCoverage

asn_pack.c

Absolute File Name:/home/opencoverage/opencoverage/guest-scripts/openssl/src/crypto/asn1/asn_pack.c
Switch to Source codePreprocessed file
LineSourceCount
1-
2-
3-
4ASN1_STRING *ASN1_item_pack(void *obj, const ASN1_ITEM *it, ASN1_STRING **oct)-
5{-
6 ASN1_STRING *octmp;-
7-
8 if (oct ==
oct == ((void *)0)Description
TRUEevaluated 6 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
FALSEevaluated 7 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
6-7
9 ((void *)0)
oct == ((void *)0)Description
TRUEevaluated 6 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
FALSEevaluated 7 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
6-7
10 || *
*oct == ((void *)0)Description
TRUEevaluated 7 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
FALSEnever evaluated
oct ==
*oct == ((void *)0)Description
TRUEevaluated 7 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
FALSEnever evaluated
0-7
11 ((void *)0)
*oct == ((void *)0)Description
TRUEevaluated 7 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
FALSEnever evaluated
0-7
12 ) {-
13 if ((
(octmp = ASN1_...== ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 13 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
octmp = ASN1_STRING_new()) ==
(octmp = ASN1_...== ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 13 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
0-13
14 ((void *)0)
(octmp = ASN1_...== ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 13 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
0-13
15 ) {-
16 ERR_put_error(13,(198),((1|64)),__FILE__,22);-
17 return
never executed: return ((void *)0) ;
never executed: return ((void *)0) ;
0
18 ((void *)0)
never executed: return ((void *)0) ;
0
19 ;
never executed: return ((void *)0) ;
0
20 }-
21 }
executed 13 times by 1 test: end of block
Executed by:
  • libcrypto.so.1.1
else {
13
22 octmp = *oct;-
23 }
never executed: end of block
0
24-
25 CRYPTO_free(octmp->data, __FILE__, 29);-
26 octmp->data = -
27 ((void *)0)-
28 ;-
29-
30 if ((
(octmp->length...ata, it)) == 0Description
TRUEnever evaluated
FALSEevaluated 13 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
octmp->length = ASN1_item_i2d(obj, &octmp->data, it)) == 0
(octmp->length...ata, it)) == 0Description
TRUEnever evaluated
FALSEevaluated 13 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
) {
0-13
31 ERR_put_error(13,(198),(112),__FILE__,33);-
32 goto
never executed: goto err;
err;
never executed: goto err;
0
33 }-
34 if (octmp->data ==
octmp->data == ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 13 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
0-13
35 ((void *)0)
octmp->data == ((void *)0)Description
TRUEnever evaluated
FALSEevaluated 13 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
0-13
36 ) {-
37 ERR_put_error(13,(198),((1|64)),__FILE__,37);-
38 goto
never executed: goto err;
err;
never executed: goto err;
0
39 }-
40-
41 if (oct !=
oct != ((void *)0)Description
TRUEevaluated 7 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
FALSEevaluated 6 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
6-7
42 ((void *)0)
oct != ((void *)0)Description
TRUEevaluated 7 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
FALSEevaluated 6 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
6-7
43 && *
*oct == ((void *)0)Description
TRUEevaluated 7 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
FALSEnever evaluated
oct ==
*oct == ((void *)0)Description
TRUEevaluated 7 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
FALSEnever evaluated
0-7
44 ((void *)0)
*oct == ((void *)0)Description
TRUEevaluated 7 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
FALSEnever evaluated
0-7
45 )-
46 *
executed 7 times by 1 test: *oct = octmp;
Executed by:
  • libcrypto.so.1.1
oct = octmp;
executed 7 times by 1 test: *oct = octmp;
Executed by:
  • libcrypto.so.1.1
7
47-
48 return
executed 13 times by 1 test: return octmp;
Executed by:
  • libcrypto.so.1.1
octmp;
executed 13 times by 1 test: return octmp;
Executed by:
  • libcrypto.so.1.1
13
49 err:-
50 if (oct ==
oct == ((void *)0)Description
TRUEnever evaluated
FALSEnever evaluated
0
51 ((void *)0)
oct == ((void *)0)Description
TRUEnever evaluated
FALSEnever evaluated
0
52 || *
*oct == ((void *)0)Description
TRUEnever evaluated
FALSEnever evaluated
oct ==
*oct == ((void *)0)Description
TRUEnever evaluated
FALSEnever evaluated
0
53 ((void *)0)
*oct == ((void *)0)Description
TRUEnever evaluated
FALSEnever evaluated
0
54 )-
55 ASN1_STRING_free(octmp);
never executed: ASN1_STRING_free(octmp);
0
56 return
never executed: return ((void *)0) ;
never executed: return ((void *)0) ;
0
57 ((void *)0)
never executed: return ((void *)0) ;
0
58 ;
never executed: return ((void *)0) ;
0
59}-
60-
61-
62-
63void *ASN1_item_unpack(const ASN1_STRING *oct, const ASN1_ITEM *it)-
64{-
65 const unsigned char *p;-
66 void *ret;-
67-
68 p = oct->data;-
69 if ((
(ret = ASN1_it...== ((void *)0)Description
TRUEevaluated 124 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
FALSEevaluated 192 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
ret = ASN1_item_d2i(
(ret = ASN1_it...== ((void *)0)Description
TRUEevaluated 124 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
FALSEevaluated 192 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
124-192
70 ((void *)0)
(ret = ASN1_it...== ((void *)0)Description
TRUEevaluated 124 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
FALSEevaluated 192 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
124-192
71 , &p, oct->length, it)) ==
(ret = ASN1_it...== ((void *)0)Description
TRUEevaluated 124 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
FALSEevaluated 192 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
124-192
72 ((void *)0)
(ret = ASN1_it...== ((void *)0)Description
TRUEevaluated 124 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
FALSEevaluated 192 times by 1 test
Evaluated by:
  • libcrypto.so.1.1
124-192
73 )-
74 ERR_put_error(13,(199),(110),__FILE__,60);
executed 124 times by 1 test: ERR_put_error(13,(199),(110),__FILE__,60);
Executed by:
  • libcrypto.so.1.1
124
75 return
executed 316 times by 1 test: return ret;
Executed by:
  • libcrypto.so.1.1
ret;
executed 316 times by 1 test: return ret;
Executed by:
  • libcrypto.so.1.1
316
76}-
Switch to Source codePreprocessed file

Generated by Squish Coco 4.2.2