aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/php
diff options
context:
space:
mode:
authorGravatar Alexander Polcyn <apolcyn@google.com>2017-04-26 14:18:39 -0700
committerGravatar Alexander Polcyn <apolcyn@google.com>2017-04-26 14:18:39 -0700
commitf5521c33f9094f2f1e416764c4d2020237d65bc6 (patch)
treee8ef2105ec499e1ebf6e840bb0140e5f1c29550d /src/php
parent79759fea1abd09102d38af3e13a84b69e898124b (diff)
Revert "Merge branch 'master' into v1.3.x"
Diffstat (limited to 'src/php')
-rw-r--r--src/php/composer.json2
-rw-r--r--src/php/ext/grpc/call.c2
-rw-r--r--src/php/ext/grpc/completion_queue.c5
-rw-r--r--src/php/lib/Grpc/BaseStub.php2
4 files changed, 7 insertions, 4 deletions
diff --git a/src/php/composer.json b/src/php/composer.json
index 24c17c3b57..2b140077cc 100644
--- a/src/php/composer.json
+++ b/src/php/composer.json
@@ -2,7 +2,7 @@
"name": "grpc/grpc-dev",
"description": "gRPC library for PHP - for Developement use only",
"license": "BSD-3-Clause",
- "version": "1.4.0",
+ "version": "1.3.0",
"require": {
"php": ">=5.5.0",
"google/protobuf": "^v3.1.0"
diff --git a/src/php/ext/grpc/call.c b/src/php/ext/grpc/call.c
index d3fd88416b..48a374fa08 100644
--- a/src/php/ext/grpc/call.c
+++ b/src/php/ext/grpc/call.c
@@ -65,7 +65,7 @@ static zend_object_handlers call_ce_handlers;
/* Frees and destroys an instance of wrapped_grpc_call */
PHP_GRPC_FREE_WRAPPED_FUNC_START(wrapped_grpc_call)
if (p->owned && p->wrapped != NULL) {
- grpc_call_unref(p->wrapped);
+ grpc_call_destroy(p->wrapped);
}
PHP_GRPC_FREE_WRAPPED_FUNC_END()
diff --git a/src/php/ext/grpc/completion_queue.c b/src/php/ext/grpc/completion_queue.c
index c75a524530..741204b0b1 100644
--- a/src/php/ext/grpc/completion_queue.c
+++ b/src/php/ext/grpc/completion_queue.c
@@ -38,10 +38,13 @@
grpc_completion_queue *completion_queue;
void grpc_php_init_completion_queue(TSRMLS_D) {
- completion_queue = grpc_completion_queue_create_for_pluck(NULL);
+ completion_queue = grpc_completion_queue_create(NULL);
}
void grpc_php_shutdown_completion_queue(TSRMLS_D) {
grpc_completion_queue_shutdown(completion_queue);
+ while (grpc_completion_queue_next(completion_queue,
+ gpr_inf_future(GPR_CLOCK_REALTIME),
+ NULL).type != GRPC_QUEUE_SHUTDOWN);
grpc_completion_queue_destroy(completion_queue);
}
diff --git a/src/php/lib/Grpc/BaseStub.php b/src/php/lib/Grpc/BaseStub.php
index 24934491b4..ed504f85a8 100644
--- a/src/php/lib/Grpc/BaseStub.php
+++ b/src/php/lib/Grpc/BaseStub.php
@@ -87,7 +87,7 @@ class BaseStub
'ChannelCredentials::create methods');
}
if ($channel) {
- if (!is_a($channel, 'Grpc\Channel')) {
+ if (!is_a($channel, 'Channel')) {
throw new \Exception('The channel argument is not a'.
'Channel object');
}