Closed citreae535 closed 1 year ago
Those println!
are changed because this clippy lint, uninlined_format_args, shows up as warnings by default in 1.67.0
. It was changed to allow in 1.67.1
but the maintainers said they "should restore this when rust-analyzer support gets better". As long as it is consistent I don't really have a strong opinion on this. Might be a good idea adding a clippy.toml
if the old way is preferable.
This one can wait for #89 to make use of that error helper function in the example.
Just rebased it. Should be ready to merge.
We had a call to thread::sleep()
in uninstall example to let the service stop. Do you think we should keep it to be on the safe side? Feels like there can be a race between the call to stop the service and service_manager.open_service()
.
@citreae535 previous PRs are already merged so you could perhaps rebase this one and see my other comment above too.
The uninstall example now polls for service stop and deletion with a timeout.
Merged. Good work & thanks for contributions! 👍
The underlying win32 API call merely marks the service for deletion. It can be called even if the service is not stopped and will not invalidate the caller's open handle to it. Making the function not consuming self allows the caller to decide when to close the handle. Docs and examples are updated to show the correct behavior of this API.
This change is