You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@qpid.apache.org by "Adel Boutros (JIRA)" <ji...@apache.org> on 2016/10/31 19:32:59 UTC

[jira] [Updated] (PROTON-1336) [Proton-c 0.14.0][Visual Studio 2013] Failing ssl unit test only in Debug mode

     [ https://issues.apache.org/jira/browse/PROTON-1336?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Adel Boutros updated PROTON-1336:
---------------------------------
    Description: 
check full details here: http://qpid.2158936.n2.nabble.com/Proton-c-0-14-0-Visual-Studio-2013-Failing-ssl-unit-test-only-in-Debug-mode-td7652076.html

Suggested patch by Cliff is tested and working

{code}
--- proton/proton-c/src/windows/io.c    2016-08-16 06:02:21 -0700 
+++ new/proton-c/src/windows/io.c    2016-10-19 16:19:21 -0700 
@@ -90,8 +90,11 @@ 
 void pn_io_finalize(void *obj) 
 { 
   pn_io_t *io = (pn_io_t *) obj; 
-  pn_error_free(io->error); 
+  pn_selector_t *sel = io->iocp->selector; 
   pn_free(io->iocp); 
+  if (sel) 
+    pn_decref(sel); 
+  pn_error_free(io->error); 
   WSACleanup(); 
 } 

@@ -366,8 +369,10 @@ 

 pn_selector_t *pn_io_selector(pn_io_t *io) 
 { 
-  if (io->iocp->selector == NULL) 
+  if (io->iocp->selector == NULL) { 
     io->iocp->selector = pni_selector_create(io->iocp); 
+    pn_incref(io->iocp->selector); 
+  } 
   return io->iocp->selector; 
 } 
{code}

  was:
check full details here: http://qpid.2158936.n2.nabble.com/Proton-c-0-14-0-Visual-Studio-2013-Failing-ssl-unit-test-only-in-Debug-mode-td7652076.html

Suggested patch by Cliff is tested and working

--- proton/proton-c/src/windows/io.c    2016-08-16 06:02:21 -0700 
+++ new/proton-c/src/windows/io.c    2016-10-19 16:19:21 -0700 
@@ -90,8 +90,11 @@ 
 void pn_io_finalize(void *obj) 
 { 
   pn_io_t *io = (pn_io_t *) obj; 
-  pn_error_free(io->error); 
+  pn_selector_t *sel = io->iocp->selector; 
   pn_free(io->iocp); 
+  if (sel) 
+    pn_decref(sel); 
+  pn_error_free(io->error); 
   WSACleanup(); 
 } 

@@ -366,8 +369,10 @@ 

 pn_selector_t *pn_io_selector(pn_io_t *io) 
 { 
-  if (io->iocp->selector == NULL) 
+  if (io->iocp->selector == NULL) { 
     io->iocp->selector = pni_selector_create(io->iocp); 
+    pn_incref(io->iocp->selector); 
+  } 
   return io->iocp->selector; 
 } 


> [Proton-c 0.14.0][Visual Studio 2013] Failing ssl unit test only in Debug mode
> ------------------------------------------------------------------------------
>
>                 Key: PROTON-1336
>                 URL: https://issues.apache.org/jira/browse/PROTON-1336
>             Project: Qpid Proton
>          Issue Type: Bug
>          Components: proton-c
>    Affects Versions: 0.14.0
>            Reporter: Adel Boutros
>
> check full details here: http://qpid.2158936.n2.nabble.com/Proton-c-0-14-0-Visual-Studio-2013-Failing-ssl-unit-test-only-in-Debug-mode-td7652076.html
> Suggested patch by Cliff is tested and working
> {code}
> --- proton/proton-c/src/windows/io.c    2016-08-16 06:02:21 -0700 
> +++ new/proton-c/src/windows/io.c    2016-10-19 16:19:21 -0700 
> @@ -90,8 +90,11 @@ 
>  void pn_io_finalize(void *obj) 
>  { 
>    pn_io_t *io = (pn_io_t *) obj; 
> -  pn_error_free(io->error); 
> +  pn_selector_t *sel = io->iocp->selector; 
>    pn_free(io->iocp); 
> +  if (sel) 
> +    pn_decref(sel); 
> +  pn_error_free(io->error); 
>    WSACleanup(); 
>  } 
> @@ -366,8 +369,10 @@ 
>  pn_selector_t *pn_io_selector(pn_io_t *io) 
>  { 
> -  if (io->iocp->selector == NULL) 
> +  if (io->iocp->selector == NULL) { 
>      io->iocp->selector = pni_selector_create(io->iocp); 
> +    pn_incref(io->iocp->selector); 
> +  } 
>    return io->iocp->selector; 
>  } 
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org
For additional commands, e-mail: dev-help@qpid.apache.org