summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2013-03-31tmpfiles: fix obscure leak in error pathZbigniew Jędrzejewski-Szmek
The leak was because of the single return in midst of all 'goto finish'es. Using automatic cleanup simplifies things.
2013-03-31ModernizationZbigniew Jędrzejewski-Szmek
Use _cleanup_ and wrap lines to ~80 chars and such.
2013-03-31strbuf: replace quick sort with bubble sortZbigniew Jędrzejewski-Szmek
No need to call the heavy artillery, when the original array is sorted. Reduces complexity from n² log n to n log n, where n is the number of items in the array, not very large, but still.
2013-03-31strbuf: fix leak on memory errorZbigniew Jędrzejewski-Szmek
Not very likely, but let's fix it for the matter of principle.
2013-03-31bootchart: fix a potential buffer overrunZbigniew Jędrzejewski-Szmek
If the configured number of samples was close to MAXSAMPLES, the samples buffer could be overrun: - by 1, because of off-by-one in the condition (samples > arg_samples_len), and - by many in case of an overrun, because the number of samples to capture was increased, instead of being decreased. Simplify things by converting to a normal for-loop. In store.c: change buffer size from 4095 to 4096. 4095 is a strange number.
2013-03-31bootchart: split out option parsing from main()Zbigniew Jędrzejewski-Szmek
2013-03-31journald: check return value of strappendZbigniew Jędrzejewski-Szmek
2013-03-31bus: check return value from bus_type_get_alignment/sizeZbigniew Jędrzejewski-Szmek
2013-03-31nspawn, machine-id-setup: warn if read-only mount call failsZbigniew Jędrzejewski-Szmek
They are not crucial, but they shouldn't fail.
2013-03-31nss-myhostname: use _cleanup_ and split function into twoZbigniew Jędrzejewski-Szmek
The triply nested loop is just too much. Let's split out the middle loop's body, so the whole thing is easier to read. Also modernize the style a bit, using structure initialization to avoid memset and such.
2013-03-31accelerometer: remove dead if and modernizeZbigniew Jędrzejewski-Szmek
Based on a coverity warning.
2013-03-31execute: convert secure bits into mask properlyZbigniew Jędrzejewski-Szmek
C.f. http://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=5975c725dfd6f7d36f493ab1453fbdbd35c1f0e3
2013-03-31Remove some dead codeZbigniew Jędrzejewski-Szmek
Based on coverity report.
2013-03-31journal-gatewayd: query PID 1 for virtalizationLennart Poettering
Since journal-gatewayd is now running unprivileged, and detecting virtalization requires privileges, query PID1 via D-Bus for the used virtualization. This is also the first time we use libsystemd-bus for more than just testing. https://bugs.freedesktop.org/show_bug.cgi?id=62173
2013-03-31bus: rename sd_bus_get_peer() to sd_bus_get_server_id()Lennart Poettering
This function always returns the server side ID. The name suggested it was actually always the peer's ID, but that's not correct if the call is called on a server bus context. Hence, let's correct the name a bit.
2013-03-31bus: s/sd_message_handler_t/sd_bus_message_handler_t/gLennart Poettering
2013-03-31bus: parse matches locally and allow registration of callbacks for themLennart Poettering
This includes code to parse and split up match strings which will also be useful to calculate bloom filter masks when the time comes.
2013-03-30bus: add missing test-bus-server.cLennart Poettering
2013-03-30bus: implement server mode, and anonymous authenticationLennart Poettering
2013-03-30prioq: consider a NULL prioq emptyLennart Poettering
2013-03-30bus: if we recieve fds but fd passing is off, consider this an errorLennart Poettering
2013-03-30bus: enable SO_PASSCRED only if we are not connected to a busLennart Poettering
2013-03-30bus: properly set up bus connections with sd_bus_set_exec()Lennart Poettering
2013-03-30bus: consider it an error if the first message we get on the bus is not a ↵Lennart Poettering
reply to HELLO
2013-03-30bus: add C++ wrappers to public header filesLennart Poettering
2013-03-30dbus: let's make this const array staticLennart Poettering
2013-03-30udev: extern on functions is pointlessLennart Poettering
2013-03-30unit: no need to export variables if we can avoid itLennart Poettering
2013-03-30TODOLennart Poettering
2013-03-30gitignore: updateKay Sievers
2013-03-30TODO: updateKay Sievers
2013-03-30killall: print notice what we forcefully KILLKay Sievers
2013-03-29build-sys: force Python to write UTF-8Kelly Anderson
Here is a patch that fixes documentation with python 3.x in non utf-8 locales. Specifically in my locale latin-1 is the default setting for output going to stdout, which causes it to fail. By writing directly to file we are able to set the locale to utf-8.
2013-03-29build-sys,man: use XML entities to substite stringsZbigniew Jędrzejewski-Szmek
This makes it easier to add substitutions to man pages, avoiding the separate transformation step. mkdir -p's are removed from the rule, because xsltproc will will create directories on it's own. All in all, two or three forks per man page are avoided, which should make things marginally faster. Unfortunately python parsers must too be tweaked to handle entities. This isn't particularly easy: with lxml a custom Resolver can be used, but the stdlib etree doesn't support external entities *at all*. So when running without lxml, the entities are just removed. Right now it doesn't matter, since the entities are not indexed anyway. But I intend to add indexing of filenames in the near future, and then the index generated without lxml might be missing a few lines. Oh well.
2013-03-29build-sys: generate sed substitution from a listZbigniew Jędrzejewski-Szmek
I want to use the substitutions in different form for xml entities.
2013-03-29Revert "build-sys: substitute strings in systemd.unit(5)"Zbigniew Jędrzejewski-Szmek
This reverts commits c78ab91132aab9193f3c17a9a206f8825ff4be84 and 185c3be03cec26023acc11b49553753aa7330a1d. It is simpler to just use includes...
2013-03-29test-path-util: fix another stupid test failureZbigniew Jędrzejewski-Szmek
2013-03-29units: fix network-online.target fieldsLennart Poettering
2013-03-29update TODOLennart Poettering
2013-03-29test-path-util: fix botched testZbigniew Jędrzejewski-Szmek
2013-03-29bootctl: fix help textKoen Kooi
It currently says 'time settings', change that to 'boot settings'.
2013-03-29utmp: make gcc shut up, we need to pass an int here, not size_tLennart Poettering
2013-03-29cgtop --help: default depth is 3 not 2Maksim Melnikau
use default depth from variable for --help
2013-03-29Always use errno > 0 to help gccZbigniew Jędrzejewski-Szmek
gcc thinks that errno might be negative, and functions could return something positive on error (-errno). Should not matter in practice, but makes an -O4 build much quieter.
2013-03-29journalctl: fix --update-catalog with not --root argZbigniew Jędrzejewski-Szmek
grawity> `journalctl --update-catalog` from latest git prints: "Recursive mkdir .: Invalid argument" and "Failed to write : Invalid argument"
2013-03-28tests: add some silly tests for path-util.cZbigniew Jędrzejewski-Szmek
2013-03-28journalctl: support --root for message catalogsZbigniew Jędrzejewski-Szmek
2013-03-28catalog: open up catalog internalsZbigniew Jędrzejewski-Szmek
In order to write tests for the catalog functions, they are made non-static and start taking a 'database' parameter, which is the name of a file with the preprocessed catalog entries. This makes it possible to make test-catalog part of the normal test suite, since it now only operates on files in /tmp. Some more tests are added.
2013-03-28catalog: make sure strings are terminatedZbigniew Jędrzejewski-Szmek
Coverity complains: systemd-199/src/journal/catalog.c:126: buffer_size_warning: Calling strncpy with a maximum size argument of 32 bytes on destination array "i->language" of size 32 bytes might leave the destination string unterminated. ...and unfortunately it was right. The string was defined as a fixed-size string in some parts of the code, and used a null-terminated string in others (e.g. in log statements). There's no point in conserving one byte, so just define the max language tag length to 31 bytes, and use null terminated strings everywhere. Also, wrap some lines, zero-fill less bytes, use '\0' instead of just 0 to be more explicit that this is one byte.
2013-03-28udev: check return value of uname.Václav Pavlín