]> code.delx.au - pulseaudio/blobdiff - src/pulsecore/sink-input.c
dbus: first restart timer, then dispatch it
[pulseaudio] / src / pulsecore / sink-input.c
index 9b4edeb9582795213860d43aa095337b508f2c46..395110b7fe412656dc35c52f622ab8ec4cfd833c 100644 (file)
@@ -842,7 +842,7 @@ void pa_sink_input_process_rewind(pa_sink_input *i, size_t nbytes /* in sink sam
         /* We were asked to drop all buffered data, and rerequest new
          * data from implementor the next time push() is called */
 
-        pa_memblockq_flush_write(i->thread_info.render_memblockq);
+        pa_memblockq_flush_write(i->thread_info.render_memblockq, TRUE);
 
     } else if (i->thread_info.rewrite_nbytes > 0) {
         size_t max_rewrite, amount;
@@ -1061,7 +1061,7 @@ void pa_sink_input_update_proplist(pa_sink_input *i, pa_update_mode_t mode, pa_p
     if (p)
         pa_proplist_update(i->proplist, mode, p);
 
-    if (PA_SINK_IS_LINKED(i->state)) {
+    if (PA_SINK_INPUT_IS_LINKED(i->state)) {
         pa_hook_fire(&i->core->hooks[PA_CORE_HOOK_SINK_INPUT_PROPLIST_CHANGED], i);
         pa_subscription_post(i->core, PA_SUBSCRIPTION_EVENT_SINK_INPUT|PA_SUBSCRIPTION_EVENT_CHANGE, i->index);
     }
@@ -1769,7 +1769,7 @@ static void sink_input_rewind_ramp_info(pa_sink_input *i, size_t nbytes) {
     if (!i->thread_info.ramp_info.envelope_dead) {
         int32_t envelope_length;
 
-       pa_assert(i->thread_info.ramp_info.envelope);
+        pa_assert(i->thread_info.ramp_info.envelope);
 
         envelope_length = pa_envelope_length(i->thread_info.ramp_info.envelope);
 
@@ -1780,7 +1780,7 @@ static void sink_input_rewind_ramp_info(pa_sink_input *i, size_t nbytes) {
                 i->thread_info.ramp_info.is_ramping = TRUE;
             }
         } else if (i->thread_info.ramp_info.envelope_dying < envelope_length) {
-            if ((i->thread_info.ramp_info.envelope_dying - nbytes) <= 0) {
+            if ((i->thread_info.ramp_info.envelope_dying - (ssize_t) nbytes) <= 0) {
                 pa_log_debug("Envelope Restart");
                 pa_envelope_restart(i->thread_info.ramp_info.envelope);
             }