Age | Commit message (Collapse) | Author |
|
|
|
need to duplicate that
|
|
|
|
safe_close()
Save/restore errno, like we do in safe_close(). And don't fork a thread
if the parameter is already negative.
|
|
|
|
This way we can use it on non-const strings, and don't end up with a
const'ified result.
This is similar to libc's strstr() which also takes a const string but
returns a non-const one.
|
|
|
|
This turns journalctl to the counterpart of systemd-cat.
Messages sent with
systemd-cat --identifier foo --prioritiy debug
can now be shown with
journalctl --identifier foo --prioritiy debug
"--identifier" is not merged with "--unit" to make a clear
distinction between syslog and systemd units.
syslog identifiers can be chosen freely by anyone.
|
|
This is a prerequisite for integrating sd-event into an external
event loop.
|
|
Found by Lukáš Nykrýn.
|
|
|
|
|
|
|
|
Discovered by Lukas Nykryn
|
|
a->rrsig.type_covered != a->rrsig.type_covered" is always false
regardless of the values of its operands because those operands are identical.
|
|
operate on a root directory that's not /
This should make sure no UUID from the host systemd-machine-id-setup is
running on leaks onto a disk image that is provisioned with the tool.
|
|
|
|
Previously systemctl died with message
-bash-4.2# systemctl --root /rawhi list-unit-files
(src/systemctl/systemctl.c:868) Out of memory.
in the case that no unit files were found in the --root
or the directory did not exist.
So lets return ENOENT in the case that --root does not exist
and empty list in the case that there are no unit files.
|
|
|
|
|
|
|
|
|
|
|
|
align --help texts
Negative switches are a bad un-normalized thing. We alerady have some,
but we should try harder to avoid intrdoucing new ones.
Hence, instead of adding two switches:
--foobar
--no-foobar
Let's instead use the syntax
--foobar
--foobar=yes
--foobar=no
Where the first two are equivalent. The boolean argument is parsed
following the usual rules.
Change all new negative switches this way.
This patch also properly aligns the --help table, so that single char
switches always get a column separate of the long switches.
|
|
|
|
|
|
|
|
|
|
Needed for the stdin case where it could otherwise end up being used
uninitialized.
|
|
|
|
|
|
|
|
else is proper UTF8
|
|
|
|
If a name was passed in as function argument, trust it, and don't do utf-8
encoding for them. Callers are obliged to check the names themselves, and
escape them in case they use anything they got from the outside world.
|
|
This is what we have done so far for all other time values, and hence we
should do this here. This indicates the default unit of time values
specified here, if they don't contain a unit.
|
|
|
|
|
|
As memfds are now created by proper kernel API, and not by our functions, we
can't rely on names being escaped/unescaped according to our current logic.
Thus, the only safe way is to remove the escaping and when reading names,
just escape names that are not properly encoded in UTF-8.
Also, remove assert(name) lines from the memfd creation functions, as we
explictly allow name to be NULL.
|
|
Now, that the memfd stuff is not exported anymore, we can simplify a few
things:
Use assert() instead of assert_return(), since this is used internally
only, and we should be less permissive then.
No need to pass an allocated fd back by call-by-reference, we can just
directly return it.
|
|
|
|
This reverts commit cf8bd44339b00330fdbc91041d6731ba8aba9fec.
Needs more discussion on the mailing list.
|
|
UIDs/GIDs from
This way we can guarantee a limited amount of compatibility with
login.defs, by generate an appopriate "r" line out of it, on package
installation.
|
|
operstate
https://bugs.freedesktop.org/show_bug.cgi?id=81287
|
|
This makes possible to spawn service instances triggered by socket with
MLS/MCS SELinux labels which are created based on information provided by
connected peer.
Implementation of label_get_child_label derived from xinetd.
Reviewed-by: Paul Moore <pmoore@redhat.com>
|
|
As the comment says, the passed in callback must always be invoked, or the underlying link
will hang. This was missed when reworking the code, so add it back in.
|
|
We are only guaranteed to stay in ENSLAVING state whilst enslaving by bridges/bonds, not
when adding stacked devices (as then the underlying device can be IFF_UP'ed and configured
in parallel), so drop these asserts.
|
|
|
|
|
|
|