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
47c8e475
Commit
47c8e475
authored
Mar 26, 2017
by
Lev Walkin
Committed by
GitHub
Mar 26, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #104 from velichkov/asn1c_make_identifier_segfault
Fix segmentation fault in asn1c_make_identifier
parents
06a37c85
febd3d5a
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
6 deletions
+6
-6
asn1c/tests/check-assembly.sh
asn1c/tests/check-assembly.sh
+1
-1
libasn1compiler/asn1c_misc.c
libasn1compiler/asn1c_misc.c
+5
-5
No files found.
asn1c/tests/check-assembly.sh
View file @
47c8e475
...
...
@@ -17,7 +17,7 @@ abs_top_srcdir="${abs_top_srcdir:-$(pwd)/../../}"
abs_top_builddir
=
"
${
abs_top_builddir
:-
$(
pwd
)
/../../
}
"
if
echo
"
$*
"
|
grep
-q
--
--
;
then
TEST_DRIVER
=
$(
echo
"
$*
"
|
sed
-e
's/ -- .*/
--
/g'
)
TEST_DRIVER
=
$(
echo
"
$*
"
|
sed
-e
's/ -- .*/
--
/g'
)
source_full
=
$(
echo
"
$*
"
|
sed
-e
's/.* //g'
)
else
TEST_DRIVER
=
""
...
...
libasn1compiler/asn1c_misc.c
View file @
47c8e475
...
...
@@ -263,7 +263,7 @@ asn1c_type_name(arg_t *arg, asn1p_expr_t *expr, enum tnfmt _format) {
switch
(
_format
)
{
case
TNF_UNMODIFIED
:
return
asn1c_make_identifier
(
AMI_MASK_ONLY_SPACES
,
0
,
exprid
?
exprid
->
Identifier
:
typename
,
0
);
0
,
exprid
?
exprid
->
Identifier
:
typename
,
(
char
*
)
0
);
case
TNF_INCLUDE
:
return
asn1c_make_identifier
(
AMI_MASK_ONLY_SPACES
|
AMI_NODELIMITER
,
...
...
@@ -271,15 +271,15 @@ asn1c_type_name(arg_t *arg, asn1p_expr_t *expr, enum tnfmt _format) {
?
"
\"
"
:
"<"
),
exprid
?
exprid
->
Identifier
:
typename
,
((
!
stdname
||
(
arg
->
flags
&
A1C_INCLUDES_QUOTED
))
?
".h
\"
"
:
".h>"
),
0
);
?
".h
\"
"
:
".h>"
),
(
char
*
)
0
);
case
TNF_SAFE
:
return
asn1c_make_identifier
(
0
,
exprid
,
typename
,
0
);
return
asn1c_make_identifier
(
0
,
exprid
,
typename
,
(
char
*
)
0
);
case
TNF_CTYPE
:
/* C type */
return
asn1c_make_identifier
(
0
,
exprid
,
exprid
?
"t"
:
typename
,
exprid
?
0
:
"t"
,
0
);
exprid
?
"t"
:
typename
,
exprid
?
0
:
"t"
,
(
char
*
)
0
);
case
TNF_RSAFE
:
/* Recursion-safe type */
return
asn1c_make_identifier
(
AMI_CHECK_RESERVED
,
0
,
"struct"
,
" "
,
typename
,
0
);
"struct"
,
" "
,
typename
,
(
char
*
)
0
);
}
assert
(
!
"unreachable"
);
...
...
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