Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
asn1c
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Libraries
asn1c
Commits
d3faf7fc
Commit
d3faf7fc
authored
Jan 28, 2021
by
Denis Filatov
Committed by
v0-e
Nov 09, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
WITH DESCENDANTS support; tests for WITH SUCCESSORS
parent
781af821
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
111 additions
and
2 deletions
+111
-2
libasn1parser/asn1p_oid.c
libasn1parser/asn1p_oid.c
+3
-2
tests/tests-asn1c-compiler/161-imports-with-successors-OK.asn1
.../tests-asn1c-compiler/161-imports-with-successors-OK.asn1
+36
-0
tests/tests-asn1c-compiler/161-imports-with-successors-SE.asn1
.../tests-asn1c-compiler/161-imports-with-successors-SE.asn1
+36
-0
tests/tests-asn1c-compiler/162-imports-with-successors-SE.asn1
.../tests-asn1c-compiler/162-imports-with-successors-SE.asn1
+36
-0
No files found.
libasn1parser/asn1p_oid.c
View file @
d3faf7fc
...
@@ -114,10 +114,11 @@ int
...
@@ -114,10 +114,11 @@ int
asn1p_oid_compare_opt
(
const
asn1p_oid_t
*
a
,
const
asn1p_oid_t
*
b
,
int
oid_options
)
{
asn1p_oid_compare_opt
(
const
asn1p_oid_t
*
a
,
const
asn1p_oid_t
*
b
,
int
oid_options
)
{
int
r
=
asn1p_oid_compare
(
a
,
b
);
int
r
=
asn1p_oid_compare
(
a
,
b
);
if
(
oid_options
==
OID_WITH_SUCCESSORS
)
{
if
(
oid_options
==
OID_WITH_SUCCESSORS
)
{
if
(
r
==
b
->
arcs_count
)
/* positive and last arc */
if
(
r
==
a
->
arcs_count
&&
r
==
b
->
arcs_count
)
/* positive and last arc */
r
=
0
;
r
=
0
;
}
else
if
(
oid_options
==
OID_WITH_DESCENDANTS
)
{
}
else
if
(
oid_options
==
OID_WITH_DESCENDANTS
)
{
/* not supported yet */
if
(
a
->
arcs_count
==
(
0
-
r
))
r
=
0
;
}
}
return
r
;
return
r
;
}
}
...
...
tests/tests-asn1c-compiler/161-imports-with-successors-OK.asn1
0 → 100755
View file @
d3faf7fc
-- OK: Everything is fine
-- iso.org.dod.internet.private.enterprise (1.3.6.1.4.1)
-- .spelio.software.asn1c.test (9363.1.5.1)
-- .121
ModuleIMPORTS
{ iso org(3) dod(6) internet (1) private(4) enterprise(1)
spelio(9363) software(1) asn1c(5) test(1) 161 }
DEFINITIONS AUTOMATIC TAGS ::=
BEGIN
IMPORTS ImportedType
FROM ImportedModule1
{ iso org(3) dod(6) internet (1) private(4) enterprise(1)
spelio(9363) software(1) asn1c(5) test(1) 161 minor-version-1(1) }
WITH SUCCESSORS
;
Type ::= ImportedType
END
ImportedModule1
{ iso org(3) dod(6) internet (1) private(4) enterprise(1)
spelio(9363) software(1) asn1c(5) test(1) 161 minor-version-5(5)}
DEFINITIONS AUTOMATIC TAGS ::=
BEGIN
IMPORTS -- nothing --;
ImportedType ::= INTEGER
END
tests/tests-asn1c-compiler/161-imports-with-successors-SE.asn1
0 → 100755
View file @
d3faf7fc
-- OK: Everything is fine
-- iso.org.dod.internet.private.enterprise (1.3.6.1.4.1)
-- .spelio.software.asn1c.test (9363.1.5.1)
-- .121
ModuleIMPORTS
{ iso org(3) dod(6) internet (1) private(4) enterprise(1)
spelio(9363) software(1) asn1c(5) test(1) 161 }
DEFINITIONS AUTOMATIC TAGS ::=
BEGIN
IMPORTS ImportedType
FROM ImportedModule1
{ iso org(3) dod(6) internet (1) private(4) enterprise(1)
spelio(9363) software(1) asn1c(5) test(1) 161 minor-version-3(3) }
WITH SUCCESSORS
;
Type ::= ImportedType
END
ImportedModule1
{ iso org(3) dod(6) internet (1) private(4) enterprise(1)
spelio(9363) software(1) asn1c(5) test(1) 161 minor-version-2(2)}
DEFINITIONS AUTOMATIC TAGS ::=
BEGIN
IMPORTS -- nothing --;
ImportedType ::= INTEGER
END
tests/tests-asn1c-compiler/162-imports-with-successors-SE.asn1
0 → 100755
View file @
d3faf7fc
-- OK: Everything is fine
-- iso.org.dod.internet.private.enterprise (1.3.6.1.4.1)
-- .spelio.software.asn1c.test (9363.1.5.1)
-- .121
ModuleIMPORTS
{ iso org(3) dod(6) internet (1) private(4) enterprise(1)
spelio(9363) software(1) asn1c(5) test(1) 161 }
DEFINITIONS AUTOMATIC TAGS ::=
BEGIN
IMPORTS ImportedType
FROM ImportedModule1
{ iso org(3) dod(6) internet (1) private(4) enterprise(1)
spelio(9363) software(1) asn1c(5) test(1) 161 minor-version-3(3) }
WITH SUCCESSORS
;
Type ::= ImportedType
END
ImportedModule1
{ iso org(3) dod(6) internet (1) private(4) enterprise(1)
spelio(9363) software(1) asn1c(5) test(1) 161 minor-version-3(3) super-minor-version(1)}
DEFINITIONS AUTOMATIC TAGS ::=
BEGIN
IMPORTS -- nothing --;
ImportedType ::= INTEGER
END
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment