Skip to content

Conversation

cgwalters
Copy link
Member

Prep for using this in multiple places. Add unit tests.

Prep for using this in multiple places. Add unit tests.
@cgwalters cgwalters enabled auto-merge July 10, 2024 22:04
gboolean
_ostree_parse_tristate (const char *s, OtTristate *out_tri, GError **error)
{
if (strcmp (s, "maybe") == 0)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This isn't new, but "maybe" is a very confusing value to support. Feels like "auto" would capture it better?

return TRUE;
}
// If it's invalid, be clear a tristate was expected.
return glnx_throw (error, "Invalid tri-state value: %s", s);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor: looks like we're losing the G_KEY_FILE_ERROR_INVALID_VALUE semantics here.

@cgwalters cgwalters merged commit 5378fe2 into ostreedev:main Jul 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants