Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
Grpc
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
tci-gateway-module
Grpc
Commits
a9236bc4
Commit
a9236bc4
authored
Apr 28, 2017
by
Craig Tiller
Committed by
GitHub
Apr 28, 2017
Browse files
Options
Downloads
Plain Diff
Merge pull request #10824 from ctiller/proxy2
Fix potential memory leak, cleanup some code
parents
ffa74736
1c2332b0
Branches
Branches containing commit
Tags
Tags containing commit
Loading
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/core/ext/filters/http/message_compress/message_compress_filter.c
+12
-10
12 additions, 10 deletions
...t/filters/http/message_compress/message_compress_filter.c
with
12 additions
and
10 deletions
src/core/ext/filters/http/message_compress/message_compress_filter.c
+
12
−
10
View file @
a9236bc4
...
@@ -277,13 +277,10 @@ static void compress_start_transport_stream_op_batch(
...
@@ -277,13 +277,10 @@ static void compress_start_transport_stream_op_batch(
GPR_TIMER_BEGIN
(
"compress_start_transport_stream_op_batch"
,
0
);
GPR_TIMER_BEGIN
(
"compress_start_transport_stream_op_batch"
,
0
);
if
(
op
->
cancel_stream
)
{
if
(
op
->
cancel_stream
)
{
gpr_atm
cur
;
GRPC_ERROR_REF
(
op
->
payload
->
cancel_stream
.
cancel_error
);
GRPC_ERROR_REF
(
op
->
payload
->
cancel_stream
.
cancel_error
);
do
{
gpr_atm
cur
=
gpr_atm_full_xchg
(
cur
=
gpr_atm_acq_load
(
&
calld
->
send_initial_metadata_state
);
&
calld
->
send_initial_metadata_state
,
}
while
(
!
gpr_atm_rel_cas
(
CANCELLED_BIT
|
(
gpr_atm
)
op
->
payload
->
cancel_stream
.
cancel_error
);
&
calld
->
send_initial_metadata_state
,
cur
,
CANCELLED_BIT
|
(
gpr_atm
)
op
->
payload
->
cancel_stream
.
cancel_error
));
switch
(
cur
)
{
switch
(
cur
)
{
case
HAS_COMPRESSION_ALGORITHM
:
case
HAS_COMPRESSION_ALGORITHM
:
case
NO_COMPRESSION_ALGORITHM
:
case
NO_COMPRESSION_ALGORITHM
:
...
@@ -311,13 +308,18 @@ static void compress_start_transport_stream_op_batch(
...
@@ -311,13 +308,18 @@ static void compress_start_transport_stream_op_batch(
grpc_transport_stream_op_batch_finish_with_failure
(
exec_ctx
,
op
,
error
);
grpc_transport_stream_op_batch_finish_with_failure
(
exec_ctx
,
op
,
error
);
return
;
return
;
}
}
gpr_atm
cur
=
gpr_atm_acq_load
(
&
calld
->
send_initial_metadata_state
);
gpr_atm
cur
;
retry_send_im:
cur
=
gpr_atm_acq_load
(
&
calld
->
send_initial_metadata_state
);
GPR_ASSERT
(
cur
!=
HAS_COMPRESSION_ALGORITHM
&&
GPR_ASSERT
(
cur
!=
HAS_COMPRESSION_ALGORITHM
&&
cur
!=
NO_COMPRESSION_ALGORITHM
);
cur
!=
NO_COMPRESSION_ALGORITHM
);
if
((
cur
&
CANCELLED_BIT
)
==
0
)
{
if
((
cur
&
CANCELLED_BIT
)
==
0
)
{
gpr_atm_rel_store
(
&
calld
->
send_initial_metadata_state
,
if
(
!
gpr_atm_rel_cas
(
&
calld
->
send_initial_metadata_state
,
cur
,
has_compression_algorithm
?
HAS_COMPRESSION_ALGORITHM
has_compression_algorithm
:
NO_COMPRESSION_ALGORITHM
);
?
HAS_COMPRESSION_ALGORITHM
:
NO_COMPRESSION_ALGORITHM
))
{
goto
retry_send_im
;
}
if
(
cur
!=
INITIAL_METADATA_UNSEEN
)
{
if
(
cur
!=
INITIAL_METADATA_UNSEEN
)
{
grpc_call_next_op
(
exec_ctx
,
elem
,
grpc_call_next_op
(
exec_ctx
,
elem
,
(
grpc_transport_stream_op_batch
*
)
cur
);
(
grpc_transport_stream_op_batch
*
)
cur
);
...
...
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
sign in
to comment