summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2018-11-16logind: log correct error msgLennart Poettering1-1/+1
2018-11-16logind: sort includesLennart Poettering1-1/+1
2018-11-16bootctl: display loader features in a pretty way.Lennart Poettering3-0/+90
2018-11-16util: force time multiplications to happen in longsLennart Poettering1-2/+2
2018-11-16locale-util: add special glyph support for check marks/cross marksLennart Poettering3-1/+10
2018-11-16logind: also expose bool prop on bus that declares whether we are on ↵Lennart Poettering1-0/+2
external power The three core variables that affect idleness handling are whether we are docked, whether we are on AC power and whether the lid is closed, hence let's also expose the third variable on the bus, to make things nicely debuggable.
2018-11-16logind: make sure that if we can't figure out whether we are on AC we ↵Lennart Poettering1-5/+3
presume we are It's safer to assume that we are on AC than to assume we are on battery, if we can't figure it out.
2018-11-16logind: don't claim that RebootToFirmwareSetup was constantLennart Poettering1-1/+1
It's not, after all, that's what SetRebootToFirmware() is about. (I was wondering for a moment whether to make this EMITS_CHANGES, but decided against it, given that the flag actually can be changed externally to logind too, and we couldn't send out notifications for that.)
2018-11-16logind: expose a boolean on the bus explaining whether logind thinks the lid ↵Lennart Poettering3-0/+14
is closed This copies how we already expose a "Docked" boolean the reflects whether we are in a docking station or not.
2018-11-16tests: run fuzzers four times in a row (#10794)Evgeny Vereshchagin1-1/+7
This should help to catch issues that are easily detectable by bad_build_check like the one being fixed in https://github.com/systemd/systemd/pull/10793, which would totally break the build tomorrow if I hadn't run `helper.py check_build` manually.
2018-11-16sd-bus: make strict asan shut upLennart Poettering1-3/+6
asan doesn't like it if we use strndup() (i.e. a string function) on a non-NULL terminated buffer (i.e. something that isn't really a string). Let's hence use memdup_suffix0() instead of strndup(), which is more appropriate for binary data that is to become a string. Fixes: #10385
2018-11-16Merge pull request #10795 from poettering/generator-fixesZbigniew Jędrzejewski-Szmek3-2/+7
trivial fixes to some generators
2018-11-16Merge pull request #10796 from poettering/systemd-exit-service-fixesZbigniew Jędrzejewski-Szmek1-4/+4
units: corrections for systemd-exit.service
2018-11-16Merge pull request #10791 from keszybz/sd-event-get-enabledLennart Poettering3-24/+19
Some minor tweaks for sd_event_source_get_enabled
2018-11-16test: initialize syslog_fd in fuzz-journald-kmsg tooEvgeny Vereshchagin1-0/+1
This is a follow-up to 8857fb9beb9dcb that prevents the fuzzer from crashing with ``` ==220==ERROR: AddressSanitizer: ABRT on unknown address 0x0000000000dc (pc 0x7ff4953c8428 bp 0x7ffcf66ec290 sp 0x7ffcf66ec128 T0) SCARINESS: 10 (signal) #0 0x7ff4953c8427 in gsignal (/lib/x86_64-linux-gnu/libc.so.6+0x35427) #1 0x7ff4953ca029 in abort (/lib/x86_64-linux-gnu/libc.so.6+0x37029) #2 0x7ff49666503a in log_assert_failed_realm /work/build/../../src/systemd/src/basic/log.c:805:9 #3 0x7ff496614ecf in safe_close /work/build/../../src/systemd/src/basic/fd-util.c:66:17 #4 0x548806 in server_done /work/build/../../src/systemd/src/journal/journald-server.c:2064:9 #5 0x5349fa in LLVMFuzzerTestOneInput /work/build/../../src/systemd/src/fuzz/fuzz-journald-kmsg.c:26:9 #6 0x592755 in fuzzer::Fuzzer::ExecuteCallback(unsigned char const*, unsigned long) /src/libfuzzer/FuzzerLoop.cpp:571:15 #7 0x590627 in fuzzer::Fuzzer::RunOne(unsigned char const*, unsigned long, bool, fuzzer::InputInfo*, bool*) /src/libfuzzer/FuzzerLoop.cpp:480:3 #8 0x594432 in fuzzer::Fuzzer::MutateAndTestOne() /src/libfuzzer/FuzzerLoop.cpp:708:19 #9 0x5973c6 in fuzzer::Fuzzer::Loop(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, fuzzer::fuzzer_allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) /src/libfuzzer/FuzzerLoop.cpp:839:5 #10 0x574541 in fuzzer::FuzzerDriver(int*, char***, int (*)(unsigned char const*, unsigned long)) /src/libfuzzer/FuzzerDriver.cpp:764:6 #11 0x5675fc in main /src/libfuzzer/FuzzerMain.cpp:20:10 #12 0x7ff4953b382f in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x2082f) #13 0x420f58 in _start (/out/fuzz-journald-kmsg+0x420f58) ```
2018-11-16units: fix Description= of systemd-exit.serviceLennart Poettering1-1/+1
This file was probably copied from the --user version, let's use some more appropriate wording for the --system version.
2018-11-16units: use correct command to exitLennart Poettering1-1/+1
Otherwise we'll end a cyclic loop.
2018-11-16units: add the same ordering deps for systemd-exit.service as for ↵Lennart Poettering1-2/+2
systemd-poweroff.service and friends This stuff runs in containers, and should really behave the same everywhere.
2018-11-16core: show error code even when debug loggingLennart Poettering1-1/+1
2018-11-16hibernate-resume-generator: fix minor memory leak on error pathLennart Poettering1-1/+4
2018-11-16debug-generator: fix minor memory leakLennart Poettering1-0/+2
2018-11-16udev-util: read resolve_names from udev.confYu Watanabe1-1/+2
Fixes CID#1396866.
2018-11-16Merge pull request #10788 from evverx/fuzz-kmsgZbigniew Jędrzejewski-Szmek11-3/+45
tests: add a fuzzer for dev_kmsg_record
2018-11-16journal: simplify use of sd_event_source_get_enabled()Zbigniew Jędrzejewski-Szmek1-9/+5
2018-11-16journal-file: get rid of a helper variableZbigniew Jędrzejewski-Szmek1-7/+4
It doesn't really save much in code length. Having the event source named explicitly makes it easier to understand the code at a glance.
2018-11-16sd-event: make sd_event_source_get_enabled return more infoZbigniew Jędrzejewski-Szmek2-9/+11
2018-11-16sd-event: do not use assert_return for something that is not an errorZbigniew Jędrzejewski-Szmek1-1/+3
It's totally OK for description to be unset, so let's not log about this even at debug level.
2018-11-16tests: add a reproducer for a heap-buffer-overflow fixed in 937b1171378bc1000aEvgeny Vereshchagin1-0/+0
2018-11-16tests: add a reproducer for a memory leak fixed in 30eddcd51b8a472e05d3b8d1 ↵Evgeny Vereshchagin1-0/+0
in August
2018-11-16journal: fix an off-by-one error in dev_kmsg_recordEvgeny Vereshchagin1-1/+1
2018-11-16basic: remove an assertion from cunescape_oneEvgeny Vereshchagin1-1/+0
The function takes a pointer to a random block of memory and the length of that block. It shouldn't crash every time it sees a zero byte at the beginning there. This should help the dev-kmsg fuzzer to keep going.
2018-11-16tests: add a fuzzer for dev_kmsg_recordEvgeny Vereshchagin8-1/+44
2018-11-15udev-rules: fix possible assertionYu Watanabe1-1/+2
On 'remove' action, event->dev_db_clone is NULL. So, `IMPORT{db}` rule on 'remove' action triggers assertion. This fixes the issue.
2018-11-15Revert "units: lock down logind with fs namespacing options"Zbigniew Jędrzejewski-Szmek1-9/+1
2018-11-15basic/json: silence gcc warning about limited range of data typeZbigniew Jędrzejewski-Szmek1-2/+2
With gcc-7.1.1-3.fc26.aarch64: ../src/basic/json.c: In function ‘json_format’: ../src/basic/json.c:1409:40: warning: comparison is always true due to limited range of data type [-Wtype-limits] if (*q >= 0 && *q < ' ') ^~ ../src/basic/json.c: In function ‘inc_lines_columns’: ../src/basic/json.c:1762:31: warning: comparison is always true due to limited range of data type [-Wtype-limits] } else if (*s >= 0 && *s < 127) /* Process ASCII chars quickly */ ^~ Cast to (signed char) silences the warning, but a cast to (int) for some reason doesn't.
2018-11-15Merge pull request #10742 from poettering/c-utf8Zbigniew Jędrzejewski-Szmek43-331/+406
default to C.UTF-8 locale, and many improvements to env var file parsing/kernel cmdline parsing
2018-11-14Merge pull request #10753 from keszybz/pager-no-interruptLennart Poettering57-180/+225
Add mode in journalctl where ^C is handled by the pager
2018-11-14core: drop dbus queue recursion checkLennart Poettering2-9/+0
We don't dispatch the queue recursively anymore, hence let's simplify things a bit. As pointed out by @fbuihuu: https://github.com/systemd/systemd/pull/10763#discussion_r233209550
2018-11-14tests: add some tests for cmdline args containing spacesLennart Poettering1-9/+28
2018-11-14update NEWSLennart Poettering1-0/+7
2018-11-14update TODOLennart Poettering1-3/+2
2018-11-14locale-util: introduce common helper locale_variables_free() for freeing ↵Lennart Poettering5-41/+32
locale variable arrays
2018-11-14fileio: automatically add NULL sentinel to parse_env_file()Lennart Poettering25-81/+55
Let's modernize things a bit.
2018-11-14localed: be more careful with the used typesLennart Poettering1-1/+2
2018-11-14fileio: drop "newline" parameter for env file parsersLennart Poettering33-95/+81
Now that we don't (mis-)use the env file parser to parse kernel command lines there's no need anymore to override the used newline character set. Let's hence drop the argument and just "\n\r" always. This nicely simplifies our code.
2018-11-14tree-wide: replace all remaining uses of parse_env_file() for parsing ↵Lennart Poettering3-36/+34
/proc/cmdline Let's always go through the proc-cmdline.c APIs.
2018-11-14localed: no need to log twice about reload requestsLennart Poettering1-4/+2
2018-11-14localed: show proper bus error if we can in log messageLennart Poettering1-1/+1
2018-11-14localed: don't silently eat up errors, log somethingLennart Poettering1-7/+8
2018-11-14locale-setup: default to C.UTF-8Lennart Poettering1-5/+17
Most distributions already were shipping a C.UTF-8 locale and even Fedora now supports the C.UTF-8 locale, and there's clear indication that this is going upstream too. Hence, let's default to it now too, if nothing else is set. Note that this is only a fallback if noting else is set, and since distros generally configure a default for this behaviour shouldn't really change in installed systems. On new systems this makes vconsole.conf redundant.