]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
Skinny: sleep to lower CPU consomption
authorMathieu Parent <math.parent@gmail.com>
Thu, 25 Feb 2010 18:26:23 +0000 (18:26 +0000)
committerMathieu Parent <math.parent@gmail.com>
Thu, 25 Feb 2010 18:26:23 +0000 (18:26 +0000)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16825 d0543943-73ff-0310-b7d9-9358b9ac24b2

src/mod/endpoints/mod_skinny/skinny_protocol.c

index 153e05a67824dfb770ed648d72589aec55676f5e..9ce4ad6ec7d9cc94f60a2d4fe2c9081b8f9d3d48 100644 (file)
@@ -360,6 +360,9 @@ switch_status_t skinny_read_packet(listener_t *listener, skinny_message_t **req)
                        switch_clear_flag_locked(listener, LFLAG_RUNNING);
                        return SWITCH_STATUS_FALSE;
                }
+               if (do_sleep) {
+                       switch_cond_next();
+               }
        }
        return SWITCH_STATUS_SUCCESS;
 }