ChugR commented on a change in pull request #472: Dispatch 1288 1 - policy for 
outbound connectors
URL: https://github.com/apache/qpid-dispatch/pull/472#discussion_r267894583
 
 

 ##########
 File path: src/policy.c
 ##########
 @@ -425,34 +459,39 @@ bool qd_policy_open_lookup_user(
                                                         (PyObject 
*)policy->py_policy_manager,
                                                         vhost, name_buf, 
upolicy);
                 if (result2) {
-                    settings->maxFrameSize         = 
qd_entity_opt_long((qd_entity_t*)upolicy, "maxFrameSize", 0);
-                    settings->maxSessionWindow     = 
qd_entity_opt_long((qd_entity_t*)upolicy, "maxSessionWindow", 0);
-                    settings->maxSessions          = 
qd_entity_opt_long((qd_entity_t*)upolicy, "maxSessions", 0);
-                    settings->maxSenders           = 
qd_entity_opt_long((qd_entity_t*)upolicy, "maxSenders", 0);
-                    settings->maxReceivers         = 
qd_entity_opt_long((qd_entity_t*)upolicy, "maxReceivers", 0);
-                    if (!settings->allowAnonymousSender) { //don't override if 
enabled by authz plugin
-                        settings->allowAnonymousSender = 
qd_entity_opt_bool((qd_entity_t*)upolicy, "allowAnonymousSender", false);
-                    }
-                    if (!settings->allowDynamicSource) { //don't override if 
enabled by authz plugin
-                        settings->allowDynamicSource   = 
qd_entity_opt_bool((qd_entity_t*)upolicy, "allowDynamicSource", false);
+                    int truthy = PyObject_IsTrue(result2);
+                    if (truthy) {
+                        settings->maxFrameSize         = 
qd_entity_opt_long((qd_entity_t*)upolicy, "maxFrameSize", 0);
 
 Review comment:
   This function is shared by the incoming connection and outgoing connection 
handlers. The incoming connection handler needs it.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

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

Reply via email to