Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

lv2/sfizz.c: options terminator must have both key and value as 0 #323

Merged
merged 1 commit into from
Jul 18, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions lv2/sfizz.c
Original file line number Diff line number Diff line change
Expand Up @@ -413,7 +413,7 @@ instantiate(const LV2_Descriptor *descriptor,
// Check the options for the block size and sample rate parameters
if (options)
{
for (const LV2_Options_Option *opt = options; opt->value; ++opt)
for (const LV2_Options_Option *opt = options; opt->key || opt->value; ++opt)
{
if (opt->key == self->sample_rate_uri)
{
Expand Down Expand Up @@ -845,7 +845,7 @@ lv2_get_options(LV2_Handle instance, LV2_Options_Option *options)
{
sfizz_plugin_t *self = (sfizz_plugin_t *)instance;
LV2_DEBUG("[DEBUG] get_options called\n");
for (LV2_Options_Option *opt = options; opt->value; ++opt)
for (LV2_Options_Option *opt = options; opt->key || opt->value; ++opt)
{
if (self->unmap) {
LV2_DEBUG("[DEBUG] Called for an option with key (subject): %s (%s) \n",
Expand Down Expand Up @@ -878,7 +878,7 @@ lv2_set_options(LV2_Handle instance, const LV2_Options_Option *options)
sfizz_plugin_t *self = (sfizz_plugin_t *)instance;

// Update the block size and sample rate as needed
for (const LV2_Options_Option *opt = options; opt->value; ++opt)
for (const LV2_Options_Option *opt = options; opt->key || opt->value; ++opt)
{
if (opt->key == self->sample_rate_uri)
{
Expand Down