projects
/
postgres-xl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4966ce0
)
Check for connection before trying to dereference a pointer
author
Pavan Deolasee
<
[email protected]
>
Thu, 19 Nov 2015 05:09:25 +0000
(10:39 +0530)
committer
Pavan Deolasee
<
[email protected]
>
Thu, 19 Nov 2015 05:09:25 +0000
(10:39 +0530)
src/backend/pgxc/pool/poolmgr.c
patch
|
blob
|
blame
|
history
diff --git
a/src/backend/pgxc/pool/poolmgr.c
b/src/backend/pgxc/pool/poolmgr.c
index 4a756424a473cf4ced0e28c94fecb20e032f0685..c61f4211424ccb44a1bd61f5786fecbc49dbcc93 100644
(file)
--- a/
src/backend/pgxc/pool/poolmgr.c
+++ b/
src/backend/pgxc/pool/poolmgr.c
@@
-1373,6
+1373,9
@@
cancel_query_on_connections(PoolAgent *agent, List *datanodelist, List *coordlis
if (agent->dn_connections == NULL)
break;
+ if (!agent->dn_connections[node])
+ continue;
+
bRet = PQcancel((PGcancel *) agent->dn_connections[node]->xc_cancelConn, errbuf, sizeof(errbuf));
if (bRet != false)
{
@@
-1391,6
+1394,9
@@
cancel_query_on_connections(PoolAgent *agent, List *datanodelist, List *coordlis
if (agent->coord_connections == NULL)
break;
+ if (!agent->coord_connections[node])
+ continue;
+
bRet = PQcancel((PGcancel *) agent->coord_connections[node]->xc_cancelConn, errbuf, sizeof(errbuf));
if (bRet != false)
{