Skip to content

Need help understanding why calls to systemd do not work as intended #294

Answered by sangelovic
akshatd asked this question in Q&A
Discussion options

You must be logged in to vote

@akshatd Hello, good that you enjoy sdbus-c++! As per https://www.freedesktop.org/software/systemd/man/org.freedesktop.systemd1.html, the order of the return values (output arguments) from EnableUnitFiles call is: 1. carries_install_info, 2. changes. In your example, the order is inverted, hence sdbus-c++ is trying to find a vector of structures where a simple boolean lies (it fails entering the vector -- i.e. a container, hence such an error message). Try to invert both return values.

As for DisableUnitFiles call, types and order of arguments seems fine to me. And there is no related failure. So it seems the call proceeded OK. The problem will probably lie somewhere else.

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
1 reply
@akshatd
Comment options

Answer selected by akshatd
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants