Skip to content

Commit

Permalink
Do not change reset param if value is 0
Browse files Browse the repository at this point in the history
Signed-off-by: falkTX <[email protected]>
  • Loading branch information
falkTX committed Jan 16, 2025
1 parent 721c453 commit e836641
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/effects.c
Original file line number Diff line number Diff line change
Expand Up @@ -6367,7 +6367,7 @@ int effects_flush_parameters(int effect_id, int reset, int param_count, const fl
port_t *port;
float value;

if (effect->reset_index >= 0)
if (effect->reset_index >= 0 && reset != 0)
{
*(effect->ports[effect->reset_index]->buffer) = reset;
}
Expand All @@ -6393,7 +6393,7 @@ int effects_flush_parameters(int effect_id, int reset, int param_count, const fl
}

// reset a 2nd time in case plugin was processing while we changed parameters
if (effect->reset_index >= 0)
if (effect->reset_index >= 0 && reset != 0)
{
*(effect->ports[effect->reset_index]->buffer) = reset;
}
Expand Down

0 comments on commit e836641

Please sign in to comment.