1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2024-10-30 23:21:08 +03:00
Commit Graph

11113 Commits

Author SHA1 Message Date
Lennart Poettering
9d37386224 bus: consider it an error if the first message we get on the bus is not a reply to HELLO 2013-03-30 15:21:54 +01:00
Lennart Poettering
b29b8bc202 bus: add C++ wrappers to public header files 2013-03-30 15:21:54 +01:00
Lennart Poettering
166de4255c dbus: let's make this const array static 2013-03-30 15:21:54 +01:00
Lennart Poettering
bcadcb64ee udev: extern on functions is pointless 2013-03-30 15:21:54 +01:00
Lennart Poettering
830f01f0bc unit: no need to export variables if we can avoid it 2013-03-30 15:21:54 +01:00
Lennart Poettering
5a494eacbb TODO 2013-03-30 15:21:54 +01:00
Kay Sievers
e592143e5a gitignore: update 2013-03-30 15:06:51 +01:00
Kay Sievers
7db293c4a0 TODO: update 2013-03-30 15:03:09 +01:00
Kay Sievers
df758e9875 killall: print notice what we forcefully KILL 2013-03-30 14:19:40 +01:00
Kelly Anderson
95e3faefe2 build-sys: force Python to write UTF-8
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-29 20:30:22 -04:00
Zbigniew Jędrzejewski-Szmek
1a13e31d27 build-sys,man: use XML entities to substite strings
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-29 20:30:21 -04:00
Zbigniew Jędrzejewski-Szmek
4e7b3c20e0 build-sys: generate sed substitution from a list
I want to use the substitutions in different form for
xml entities.
2013-03-29 20:30:21 -04:00
Zbigniew Jędrzejewski-Szmek
aa0bb9c2c4 Revert "build-sys: substitute strings in systemd.unit(5)"
This reverts commits c78ab91132
and 185c3be03c.

It is simpler to just use includes...
2013-03-29 20:30:21 -04:00
Zbigniew Jędrzejewski-Szmek
a696dbef34 test-path-util: fix another stupid test failure 2013-03-29 20:30:21 -04:00
Lennart Poettering
1dda524f05 units: fix network-online.target fields 2013-03-29 18:31:07 +01:00
Lennart Poettering
b5c03638d4 update TODO 2013-03-29 18:31:07 +01:00
Zbigniew Jędrzejewski-Szmek
590f50130f test-path-util: fix botched test 2013-03-29 10:49:06 -04:00
Koen Kooi
8b3227c90d bootctl: fix help text
It currently says 'time settings', change that to 'boot settings'.
2013-03-29 15:47:43 +01:00
Lennart Poettering
f04c0bd6ed utmp: make gcc shut up, we need to pass an int here, not size_t 2013-03-29 15:47:18 +01:00
Maksim Melnikau
813ac7d3dd cgtop --help: default depth is 3 not 2
use default depth from variable for --help
2013-03-29 15:42:47 +01:00
Zbigniew Jędrzejewski-Szmek
8333c77edf Always use errno > 0 to help gcc
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-29 10:12:41 -04:00
Zbigniew Jędrzejewski-Szmek
0db809489f journalctl: fix --update-catalog with not --root arg
grawity> `journalctl --update-catalog` from latest git prints:
         "Recursive mkdir .: Invalid argument" and
         "Failed to write : Invalid argument"
2013-03-29 10:12:41 -04:00
Zbigniew Jędrzejewski-Szmek
76877b46b6 tests: add some silly tests for path-util.c 2013-03-28 23:45:59 -04:00
Zbigniew Jędrzejewski-Szmek
13cbf3a5f0 journalctl: support --root for message catalogs 2013-03-28 23:45:59 -04:00
Zbigniew Jędrzejewski-Szmek
844ec79b3c catalog: open up catalog internals
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-28 23:45:59 -04:00
Zbigniew Jędrzejewski-Szmek
18cd5fe99f catalog: make sure strings are terminated
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-28 23:45:59 -04:00
Václav Pavlín
f459285212 udev: check return value of uname. 2013-03-28 23:45:58 -04:00
Zbigniew Jędrzejewski-Szmek
c309a7137b bootchart: properly terminate string
systemd-199/src/bootchart/store.c:289: buffer_size_warning: Calling
strncpy with a maximum size argument of 256 bytes on destination array
"ps->name" of size 256 bytes might leave the destination string
unterminated.

...and indeed, the string was used as NULL-terminated later on.

pid_cmdline_strncpy is renamed to pid_cmdline_strscpy to commemorate
the fact that it *does* properly terminate the string.
2013-03-28 23:45:52 -04:00
Zbigniew Jędrzejewski-Szmek
2688887653 utmp-wtmp: don't try to read past end of string
systemd-199/src/shared/utmp-wtmp.c:228: buffer_size_warning: Calling
strncpy with a maximum size argument of 32 bytes on destination array
"store.ut_line" of size 32 bytes might leave the destination string
unterminated.

The destination string is unterminated on purpose, but we must
remember that.
2013-03-28 23:24:55 -04:00
Zbigniew Jędrzejewski-Szmek
c8c9c69f39 build-sys: remove papersize option from sphinx
We don't use it currently for anything (no latex output),
but it was messing up stuff if /etc/papersize had comments.
2013-03-28 22:55:52 -04:00
Zbigniew Jędrzejewski-Szmek
5e75606a41 coredump: do not free twice 2013-03-28 22:27:15 -04:00
Lennart Poettering
9ca3c17f20 build-sys: prepare release 200 2013-03-29 03:07:17 +01:00
Lennart Poettering
0c17fbce55 unit: replace remote-fs-setup.target by network-online.target
https://bugzilla.redhat.com/show_bug.cgi?id=787314
2013-03-29 03:07:17 +01:00
Kay Sievers
78a0460588 hwdb: update 2013-03-28 21:53:30 +01:00
Kay Sievers
d8d4bee76c build-sys: fix HAVE/ENABLE_FIRMWARE
https://bugs.freedesktop.org/show_bug.cgi?id=62864
2013-03-28 15:28:10 +01:00
Kay Sievers
0014c5221e bootctl: ESP --> Partition 2013-03-28 11:42:32 +01:00
Kay Sievers
33696ef458 bootctl: Binary: --> File: 2013-03-28 03:43:29 +01:00
William Douglas
f0b647223d man/os-release: Add BUILD_ID field
BUILD_ID is a fairly generic field used to identify the system image
that was used to install the distribution.
2013-03-27 11:15:07 -07:00
Lukas Nykryn
464264ac5a catalog: fix error codes handling in catalog_list_items
Previously r was set to zero and so if(r<0) was never true.
2013-03-27 12:46:36 -04:00
Lukas Nykryn
2e8fb7026d log: fix error codes handling in catalog_list_items
It does not make sense to print error code from previous loop.
2013-03-27 12:01:44 -04:00
Lukas Nykryn
531991b64d sd-bus: check c->path for null instead of path 2013-03-27 12:01:44 -04:00
Eelco Dolstra
6f6fad96ad systemd-sysctl: Handle missing /etc/sysctl.conf properly
Since fabe5c0e5f, systemd-sysctl returns
a non-zero exit code if /etc/sysctl.conf does not exist, due to a
broken ENOENT check.
2013-03-27 12:01:44 -04:00
Václav Pavlín
f36a783ca7 shared: free dt (temporary dir name) on fail
[zj: modified to not to try to rmdir() dir we haven't created.]
2013-03-27 12:01:44 -04:00
Václav Pavlín
ebf4fb3d36 core: check return value of rm_rf_dangerous and warn if it fails 2013-03-27 11:59:14 -04:00
Kay Sievers
3483fab948 bootctl: rename status output header 2013-03-27 13:55:09 +01:00
Martin Pitt
590888a0d0 keymap: Fix Touchpad Toggle on MSI Wind U90/U100
This key is handled by the hardware already, so handling it again in software
nullifies the effect. Newer kernels read the real state and send out a separate
KEY_TOUCHPAD_ON or KEY_TOUCHPAD_OFF event, so in both cases we need to ignore
that key.

https://bugs.freedesktop.org/show_bug.cgi?id=62404
2013-03-27 08:15:12 +01:00
Zbigniew Jędrzejewski-Szmek
49e5de64e2 tests: skip bus test if bus cannot be opened
To make the result more visible, special return value
is used to tell automake that the test was skipped. While
at it, use the same return value in other skipped tests.
2013-03-26 23:50:44 -04:00
Zbigniew Jędrzejewski-Szmek
f7703533a4 tests: fix size_t in format string 2013-03-26 23:50:44 -04:00
Zbigniew Jędrzejewski-Szmek
3baed19327 Simplify the meaning of %s
The rules governing %s where just too complicated. First of
all, looking at $SHELL is dangerous. For systemd --system,
it usually wouldn't be set. But it could be set if the admin
first started a debug shell, let's say /sbin/sash, and then
launched systemd from it. This shouldn't influence how daemons
are started later on, so is better ignored. Similar reasoning
holds for session mode. Some shells set $SHELL, while other
set it only when it wasn't set previously (e.g. zsh). This
results in fragility that is better avoided by ignoring $SHELL
totally.

With $SHELL out of the way, simplify things by saying that
%s==/bin/sh for root, and the configured shell otherwise.
get_shell() is the only caller, so it can be inlined.

Fixes one issue seen with 'make check'.
2013-03-26 23:49:44 -04:00
Lennart Poettering
a63a5c4687 units: automatically order all mount units after network.target
Previously it was necessary to pull in remote-fs-pre.target to order the
mount units against network.target since the ordering was done
transitively via remote-fs-pre.target.

As network implementations shouldn't need to know about the specific
use-case of network mounts we instead now simply order network.target
against all mounts too. This should make it unnecessary for network
managing services to import remote-fs-pre.target explicitly, as
network.target will now suffice.
2013-03-27 02:56:32 +01:00