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

Feature/allow disabling daemon logs #281

Merged
merged 7 commits into from
Aug 6, 2022

Conversation

michaelgruner
Copy link
Contributor

In response to #274

gstd/gstd.c Outdated Show resolved Hide resolved
@@ -100,6 +101,10 @@ main (gint argc, gchar * argv[])
{"gst-log-filename", 'd', 0, G_OPTION_ARG_FILENAME, &gstlogfile,
"Create gst.log file to path", NULL}
,
{"no-log", 'L', 0, G_OPTION_ARG_NONE, &nolog,
Copy link
Contributor

Choose a reason for hiding this comment

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

-L for the option of disabling the logging is counter-intuitive. Should we add the boolean as an argument and make it enabled by default?

gstd/gstd.c Outdated
@@ -128,7 +133,7 @@ main (gint argc, gchar * argv[])
}

if (daemon || kill) {
if (!gstd_log_init (gstdlogfile, gstlogfile)) {
if (!gstd_log_init (gstdlogfile, gstlogfile, !nolog && !kill)) {
Copy link
Contributor

Choose a reason for hiding this comment

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

This seems hard to read to me without comment. Should we separate the logic and create a boolean with the name enabled for readability and add that the logging is only enabled under certain conditions as a small comment?

@michaelgruner michaelgruner force-pushed the feature/allow-disabling-daemon-logs branch from 3252b9e to f232198 Compare August 5, 2022 23:57
@michaelgruner michaelgruner merged commit 6e765c6 into develop Aug 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants