Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
Packetdrill_tarr_ext
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Stefan Gense
Packetdrill_tarr_ext
Commits
58a1e0a0
Commit
58a1e0a0
authored
9 years ago
by
Michael Tüxen
Browse files
Options
Downloads
Patches
Plain Diff
Recursivly free expressions.
parent
7b758495
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
gtests/net/packetdrill/run_system_call.c
+1
-0
1 addition, 0 deletions
gtests/net/packetdrill/run_system_call.c
gtests/net/packetdrill/script.c
+29
-29
29 additions, 29 deletions
gtests/net/packetdrill/script.c
with
30 additions
and
29 deletions
gtests/net/packetdrill/run_system_call.c
+
1
−
0
View file @
58a1e0a0
...
...
@@ -1762,6 +1762,7 @@ static int syscall_getsockopt(struct state *state, struct syscall_spec *syscall,
begin_syscall
(
state
,
syscall
);
result
=
getsockopt
(
live_fd
,
level
,
optname
,
live_optval
,
&
live_optlen
);
if
(
end_syscall
(
state
,
syscall
,
CHECK_NON_NEGATIVE
,
result
,
error
))
{
return
STATUS_ERR
;
}
...
...
This diff is collapsed.
Click to expand it.
gtests/net/packetdrill/script.c
+
29
−
29
View file @
58a1e0a0
...
...
@@ -295,21 +295,21 @@ void free_expression(struct expression *expression)
break
;
case
EXPR_LINGER
:
assert
(
expression
->
value
.
linger
);
free
(
expression
->
value
.
linger
->
l_onoff
);
free
(
expression
->
value
.
linger
->
l_linger
);
free
_expression
(
expression
->
value
.
linger
->
l_onoff
);
free
_expression
(
expression
->
value
.
linger
->
l_linger
);
break
;
#ifdef SCTP_RTOINFO
case
EXPR_SCTP_RTOINFO
:
assert
(
expression
->
value
.
sctp_rtoinfo
);
free
(
expression
->
value
.
sctp_rtoinfo
->
srto_initial
);
free
(
expression
->
value
.
sctp_rtoinfo
->
srto_max
);
free
(
expression
->
value
.
sctp_rtoinfo
->
srto_min
);
free
_expression
(
expression
->
value
.
sctp_rtoinfo
->
srto_initial
);
free
_expression
(
expression
->
value
.
sctp_rtoinfo
->
srto_max
);
free
_expression
(
expression
->
value
.
sctp_rtoinfo
->
srto_min
);
break
;
#endif
#if defined(SCTP_MAXSEG) || defined(SCTP_MAX_BURST) || defined(SCTP_INTERLEAVING_SUPPORTED)
case
EXPR_SCTP_ASSOC_VALUE
:
assert
(
expression
->
value
.
sctp_assoc_value
);
free
(
expression
->
value
.
sctp_assoc_value
->
assoc_value
);
free
_expression
(
expression
->
value
.
sctp_assoc_value
->
assoc_value
);
break
;
#endif
#ifdef SCTP_INITMSG
...
...
@@ -321,42 +321,42 @@ void free_expression(struct expression *expression)
break
;
#ifdef SCTP_STATUS
case
EXPR_SCTP_PADDRINFO
:
free
(
expression
->
value
.
sctp_paddrinfo
);
free
(
expression
->
value
.
sctp_paddrinfo
->
spinfo_state
);
free
(
expression
->
value
.
sctp_paddrinfo
->
spinfo_cwnd
);
free
(
expression
->
value
.
sctp_paddrinfo
->
spinfo_srtt
);
free
(
expression
->
value
.
sctp_paddrinfo
->
spinfo_rto
);
free
(
expression
->
value
.
sctp_paddrinfo
->
spinfo_mtu
);
assert
(
expression
->
value
.
sctp_paddrinfo
);
free
_expression
(
expression
->
value
.
sctp_paddrinfo
->
spinfo_state
);
free
_expression
(
expression
->
value
.
sctp_paddrinfo
->
spinfo_cwnd
);
free
_expression
(
expression
->
value
.
sctp_paddrinfo
->
spinfo_srtt
);
free
_expression
(
expression
->
value
.
sctp_paddrinfo
->
spinfo_rto
);
free
_expression
(
expression
->
value
.
sctp_paddrinfo
->
spinfo_mtu
);
break
;
case
EXPR_SCTP_STATUS
:
assert
(
expression
->
value
.
sctp_status
);
free
(
expression
->
value
.
sctp_status
->
sstat_state
);
free
(
expression
->
value
.
sctp_status
->
sstat_rwnd
);
free
(
expression
->
value
.
sctp_status
->
sstat_unackdata
);
free
(
expression
->
value
.
sctp_status
->
sstat_penddata
);
free
(
expression
->
value
.
sctp_status
->
sstat_instrms
);
free
(
expression
->
value
.
sctp_status
->
sstat_outstrms
);
free
(
expression
->
value
.
sctp_status
->
sstat_fragmentation_point
);
free
(
expression
->
value
.
sctp_status
->
sstat_primary
);
free
_expression
(
expression
->
value
.
sctp_status
->
sstat_state
);
free
_expression
(
expression
->
value
.
sctp_status
->
sstat_rwnd
);
free
_expression
(
expression
->
value
.
sctp_status
->
sstat_unackdata
);
free
_expression
(
expression
->
value
.
sctp_status
->
sstat_penddata
);
free
_expression
(
expression
->
value
.
sctp_status
->
sstat_instrms
);
free
_expression
(
expression
->
value
.
sctp_status
->
sstat_outstrms
);
free
_expression
(
expression
->
value
.
sctp_status
->
sstat_fragmentation_point
);
free
_expression
(
expression
->
value
.
sctp_status
->
sstat_primary
);
break
;
#endif
#ifdef SCTP_PEER_ADDR_PARAMS
case
EXPR_SCTP_PEER_ADDR_PARAMS
:
assert
(
expression
->
value
.
sctp_paddrparams
);
free
(
expression
->
value
.
sctp_paddrparams
->
spp_address
);
free
(
expression
->
value
.
sctp_paddrparams
->
spp_hbinterval
);
free
(
expression
->
value
.
sctp_paddrparams
->
spp_pathmaxrxt
);
free
(
expression
->
value
.
sctp_paddrparams
->
spp_pathmtu
);
free
(
expression
->
value
.
sctp_paddrparams
->
spp_flags
);
free
(
expression
->
value
.
sctp_paddrparams
->
spp_ipv6_flowlabel
);
free
(
expression
->
value
.
sctp_paddrparams
->
spp_dscp
);
free
_expression
(
expression
->
value
.
sctp_paddrparams
->
spp_address
);
free
_expression
(
expression
->
value
.
sctp_paddrparams
->
spp_hbinterval
);
free
_expression
(
expression
->
value
.
sctp_paddrparams
->
spp_pathmaxrxt
);
free
_expression
(
expression
->
value
.
sctp_paddrparams
->
spp_pathmtu
);
free
_expression
(
expression
->
value
.
sctp_paddrparams
->
spp_flags
);
free
_expression
(
expression
->
value
.
sctp_paddrparams
->
spp_ipv6_flowlabel
);
free
_expression
(
expression
->
value
.
sctp_paddrparams
->
spp_dscp
);
break
;
#endif
#ifdef SCTP_SS_VALUE
case
EXPR_SCTP_STREAM_VALUE
:
assert
(
expression
->
value
.
sctp_stream_value
);
free
(
expression
->
value
.
sctp_stream_value
->
stream_id
);
free
(
expression
->
value
.
sctp_stream_value
->
stream_value
);
free
_expression
(
expression
->
value
.
sctp_stream_value
->
stream_id
);
free
_expression
(
expression
->
value
.
sctp_stream_value
->
stream_value
);
break
;
#endif
case
EXPR_WORD
:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment