-
Notifications
You must be signed in to change notification settings - Fork 89
Add notify-reload support to dbus-broker #386
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
base: main
Are you sure you want to change the base?
Conversation
2d1814f
to
cabe8fa
Compare
cabe8fa
to
ba5c384
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks a lot for the PR! Some minor comments inline.
I will try to push out a time utility, so we can rebase this PR and use it. But please bear with me until next Monday!
ba5c384
to
f54c335
Compare
Hey @dvdhrm , thanks for the review! |
f54c335
to
1e75da9
Compare
src/launch/launcher.c
Outdated
r = sd_notify(false, "RELOADING=1"); | ||
r = sd_notifyf(/* unset_environment = */ false, | ||
"RELOADING=1\n" | ||
"MONOTONIC_USEC=" USEC_FMT, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
../src/launch/launcher.c:1173:41: error: expected ‘)’ before ‘USEC_FMT’
1173 | "MONOTONIC_USEC=" USEC_FMT,
Use "MONOTONIC_USEC=%" NSEC_PRI,
instead and it should work
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also you need to pass it through nsec_to_usec()
given the helper returns nanoseconds and the API takes microseconds
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sorry, careless mistake
1e75da9
to
2d138f5
Compare
dbus-broker supports reload but the service type is
notify
. This PR updates the service type tonotify-reload
.