summaryrefslogtreecommitdiff
path: root/lib/decoding.c
diff options
context:
space:
mode:
authorNikos Mavrogiannopoulos <nmav@redhat.com>2014-06-03 15:44:49 +0200
committerNikos Mavrogiannopoulos <nmav@redhat.com>2014-06-04 10:20:18 +0200
commit4010bb04588fca86a9f6d683b637c05b4cec24e0 (patch)
treed7e5ecd8d5893040114daf92d01d355501536f14 /lib/decoding.c
parentecd1884be1d2e0f0063f82b0dd47ebe0231c3eb4 (diff)
downloadlibtasn1-4010bb04588fca86a9f6d683b637c05b4cec24e0.tar.gz
libtasn1-4010bb04588fca86a9f6d683b637c05b4cec24e0.tar.bz2
libtasn1-4010bb04588fca86a9f6d683b637c05b4cec24e0.zip
optimized _asn1_find_up().
Diffstat (limited to 'lib/decoding.c')
-rw-r--r--lib/decoding.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/lib/decoding.c b/lib/decoding.c
index 54f0167..c79a5c4 100644
--- a/lib/decoding.c
+++ b/lib/decoding.c
@@ -622,7 +622,7 @@ _asn1_delete_not_used (asn1_node node)
{
p2 = _asn1_find_left (p);
if (!p2)
- p2 = _asn1_find_up (p);
+ p2 = _asn1_get_up (p);
}
asn1_delete_structure (&p);
p = p2;
@@ -645,7 +645,7 @@ _asn1_delete_not_used (asn1_node node)
{
while (1)
{
- p = _asn1_find_up (p);
+ p = _asn1_get_up (p);
if (p == node)
{
p = NULL;
@@ -929,7 +929,7 @@ asn1_der_decoding (asn1_node * element, const void *ider, int ider_len,
{
if (p->type & CONST_SET)
{
- p2 = _asn1_find_up (p);
+ p2 = _asn1_get_up (p);
len2 = p2->tmp_ival;
if (len2 == -1)
{
@@ -985,7 +985,7 @@ asn1_der_decoding (asn1_node * element, const void *ider, int ider_len,
if ((p->type & CONST_OPTION) || (p->type & CONST_DEFAULT))
{
- p2 = _asn1_find_up (p);
+ p2 = _asn1_get_up (p);
len2 = p2->tmp_ival;
if (counter == len2)
{
@@ -1048,7 +1048,7 @@ asn1_der_decoding (asn1_node * element, const void *ider, int ider_len,
if ((p->type & CONST_OPTION) || (p->type & CONST_DEFAULT))
{
- p2 = _asn1_find_up (p);
+ p2 = _asn1_get_up (p);
len2 = p2->tmp_ival;
if ((len2 != -1) && (counter > len2))
@@ -1463,7 +1463,7 @@ asn1_der_decoding (asn1_node * element, const void *ider, int ider_len,
move = UP;
}
if (move == UP)
- p = _asn1_find_up (p);
+ p = _asn1_get_up (p);
}
_asn1_delete_not_used (*element);
@@ -1639,7 +1639,7 @@ asn1_expand_any_defined_by (asn1_node definitions, asn1_node * element)
break;
}
- p3 = _asn1_find_up (p);
+ p3 = _asn1_get_up (p);
if (!p3)
{
@@ -1659,8 +1659,8 @@ asn1_expand_any_defined_by (asn1_node definitions, asn1_node * element)
(p3->value == NULL))
{
- p3 = _asn1_find_up (p);
- p3 = _asn1_find_up (p3);
+ p3 = _asn1_get_up (p);
+ p3 = _asn1_get_up (p3);
if (!p3)
{
@@ -1795,7 +1795,7 @@ asn1_expand_any_defined_by (asn1_node definitions, asn1_node * element)
{
while (1)
{
- p = _asn1_find_up (p);
+ p = _asn1_get_up (p);
if (p == *element)
{
p = NULL;