php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Return to Bug #77606
Patch stomp-2.0.2-sslfix revision 2019-02-11 22:14 UTC by dwarren at prodpartners dot com

Patch stomp-2.0.2-sslfix for stomp Bug #77606

Patch version 2019-02-11 22:14 UTC

Return to Bug #77606 | Download this patch
Patch Revisions:

Developer: dwarren@prodpartners.com

--- stomp-2.0.2-orig/stomp.c	2018-06-29 05:10:38.000000000 -0400
+++ stomp-2.0.2/stomp.c	2019-02-11 16:47:11.386176933 -0500
@@ -370,7 +370,18 @@
 {
 	int len;
 
-	stomp_select(stomp);
+#if HAVE_STOMP_SSL
+	if(stomp->options.use_ssl) {
+		/* Don't block on FD if there is SSL data queued */
+		if (!SSL_pending(stomp->ssl_handle)) {
+			stomp_select(stomp);
+		}
+	} else {
+#endif
+		stomp_select(stomp);
+#if HAVE_STOMP_SSL
+	}
+#endif
 
 #if HAVE_STOMP_SSL
 	if(stomp->options.use_ssl) {
 
PHP Copyright © 2001-2019 The PHP Group
All rights reserved.
Last updated: Mon Aug 19 01:01:26 2019 UTC