1
0
mirror of https://github.com/systemd/systemd.git synced 2024-11-07 01:27:11 +03:00
Commit Graph

12887 Commits

Author SHA1 Message Date
Lennart Poettering
fa0fed4975 bus: fix seriliazation of activation errors 2013-11-21 02:14:05 +01:00
Lennart Poettering
14c24659cd bus: rename SD_BUS_ERROR_MAKE to SD_BUS_ERROR_MAKE_CONST to indicate it only works for const strings 2013-11-21 02:11:06 +01:00
Lennart Poettering
df2d202e6e bus: let's simplify things by getting rid of unnecessary bus parameters 2013-11-21 02:07:35 +01:00
Lennart Poettering
28383ba189 bus: add API calls to escape string components of objects paths 2013-11-21 01:03:26 +01:00
Lennart Poettering
850516e012 sd-event: try to move timer wakeups to the same spot within each minute 2013-11-21 00:46:13 +01:00
Lennart Poettering
2e41a51ea4 socket: fix segfault 2013-11-21 00:06:11 +01:00
Lennart Poettering
54b434b1b5 valgrind: make running PID 1 in valgrind useful
Since valgrind only generates useful output on exit() (rather than
exec()) we need to explicitly exit when valgrind is detected.
2013-11-20 22:12:47 +01:00
Lennart Poettering
420c7379fb nspawn: add new --drop-capability= switch 2013-11-20 22:10:42 +01:00
Lennart Poettering
1b5995b039 event: make sure to possibly disarm the timerfds before we reenter epoll_wait 2013-11-20 20:58:17 +01:00
Lennart Poettering
c57b5ca301 event: don't disarm invalid timerfd 2013-11-20 20:58:17 +01:00
Lennart Poettering
86befb4098 bus: make sure an additional ref to a busevent source doesn't cause the event source to be triggered again 2013-11-20 20:58:17 +01:00
Lennart Poettering
2576a19ed2 event: whenever a time source changes pending state reshuffle elapsation prioqs 2013-11-20 20:58:17 +01:00
Lennart Poettering
503f39c35e event: when we change the io events to watch we need to figure out if a an event is pending again 2013-11-20 20:58:17 +01:00
Lennart Poettering
a99badf5ed sd-event: fix comparison functions 2013-11-20 20:58:17 +01:00
Lennart Poettering
3772995afa manager: don't do plymouth in a container
Given that plymouth listens on an abstract namespace socket and if
CLONE_NEWNET is not used the abstract namespace is shared with the host
we might actually end up send plymouth data to the host.
2013-11-20 20:58:17 +01:00
Lennart Poettering
b51f299ae1 busctl: when no match is specified, add default match 2013-11-20 20:58:16 +01:00
Lennart Poettering
f8cfb5f5f3 bus: add color and indentation to bus_message_dump() 2013-11-20 20:58:16 +01:00
Lennart Poettering
718db96199 core: convert PID 1 to libsystemd-bus
This patch converts PID 1 to libsystemd-bus and thus drops the
dependency on libdbus. The only remaining code using libdbus is a test
case that validates our bus marshalling against libdbus' marshalling,
and this dependency can be turned off.

This patch also adds a couple of things to libsystem-bus, that are
necessary to make the port work:

- Synthesizing of "Disconnected" messages when bus connections are
  severed.

- Support for attaching multiple vtables for the same interface on the
  same path.

This patch also fixes the SetDefaultTarget() and GetDefaultTarget() bus
calls which used an inappropriate signature.

As a side effect we will now generate PropertiesChanged messages which
carry property contents, rather than just invalidation information.
2013-11-20 20:52:36 +01:00
Lennart Poettering
3febea3a0b hashmap: be a bit more conservative with pre-allocating hash tables and items 2013-11-20 19:37:02 +01:00
Lennart Poettering
e8372f7e3e install: when determining where default.target points to, accept a file instead of a symlink, too 2013-11-20 19:37:02 +01:00
Lennart Poettering
a454d241ef test: exit early if we would conflict with running user systemd 2013-11-20 19:37:02 +01:00
Lennart Poettering
911121a7c8 bus: add sd_bus_send_to() API call 2013-11-20 19:37:02 +01:00
Lennart Poettering
aea93debfa bus: bump serial number counter when sending already sealed messages 2013-11-20 19:36:14 +01:00
Lennart Poettering
80c1974018 bus: sd_bus_error_setxyz calls should always return the error as errno style negative int 2013-11-20 19:36:14 +01:00
Lennart Poettering
725d7e6ceb libudev: always return NULL in _unref() APIs
Returning anything else but NULL would suggest the caller's reference
might still be valid, but it isn't, because the caller just invoked
_unref() after all.

This turns the return value into a typesafe shortcut that allows
unreffing and resetting a reference in one line. In contrast to
solutions for this which take a pointer to a pointer to accomplish the
same this solution is just syntactic sugar the developer can make use of
but doesn't have to, and this is particularly useful when immediately
unreffing objects returned by function calls.
2013-11-20 19:36:14 +01:00
Lennart Poettering
994e023433 libudev: always return valid negative error codes on API functions 2013-11-20 19:36:14 +01:00
Lennart Poettering
135168183e calendar: support 'yearly' and 'annually' names the same way as cron 2013-11-20 19:36:14 +01:00
Lennart Poettering
8e64fd110d hwclock: modernizations 2013-11-20 19:36:14 +01:00
Lennart Poettering
d3cfcae9db macro: add _unlikely_() to assert_return()
As the name indicates assert_return() is really just for assertions,
i.e. where it's a programming error if the assertion does not hold.
Hence it is safe to add _unlikely_() decorators for the expression to
check.
2013-11-20 19:36:14 +01:00
Lennart Poettering
780dbeef9f macro: change assert_cc() so that it can appear outside of functions 2013-11-20 19:36:14 +01:00
Lennart Poettering
fd1b903adb include: make direct includion of _sd-common.h harder 2013-11-20 19:36:14 +01:00
Lennart Poettering
16ed0233a5 install: use const where we can 2013-11-20 19:36:13 +01:00
Tom Gundersen
91ffff9621 conf-parser: don't leak section names
If we encounter an unknown section, we must free the previous section before
clearing the pointer.
2013-11-20 17:54:09 +01:00
David Herrmann
0cc1125ae1 event: clear pending-state when re-arming timers
If a timer fires and is marked pending, but an application re-arms it
before it is dispatched, we now clear the pending state.

This fixes a bug where an application arms a timer, which fires and is
marked pending. But before it is dispatched, the application loses
interest in it and disables it. Now if the timer is re-armed and
re-enabled later, it will be immediately dispatched as it is still marked
pending.

This behavior is unexpected, so avoid it by clearing pending state when
re-arming timers. Note that applications have no way to clear pending
state themselves, so there's no current workaround.
2013-11-20 16:19:58 +01:00
David Herrmann
6c1508b871 bus: fix error-path in bus_map_all_properties()
We shouldn't return positive integers on errors. Fix the typo by removing
the negation.
2013-11-20 16:19:58 +01:00
Thomas Hindoe Paaboel Andersen
d7726e578a bus/rtnl: silence clang warnings 2013-11-20 12:42:43 +01:00
Tom Gundersen
0617ffabe8 networkd: make sure Links and Networks are freed 2013-11-19 14:39:19 +01:00
Jose Ignacio Naranjo
bc9cdba5dd keymap: Add Toshiba Satellite U940
Signed-off-by: Martin Pitt <martinpitt@gnome.org>
2013-11-19 08:15:50 +01:00
Zbigniew Jędrzejewski-Szmek
0732ef7acf localed: match converted keymaps before legacy
Before, X11 keymap fr-pc105-oss would be converted to fr,
even though fr-oss exists. Now, if
/usr/lib/kbd/keymaps/xkb/<layout>[-<variant>].map[.gz] exists,
<layout>[-<variant>] will be used as the console keymap,
falling back to the legacy mappings otherwise.

% sudo localectl set-x11-keymap pl pc105
% localectl
   System Locale: LANG=en_US.UTF-8
       VC Keymap: pl                      (was pl2 before)
      X11 Layout: pl
       X11 Model: pc105
% sudo localectl set-x11-keymap fr pc105 oss
% localectl
   System Locale: LANG=en_US.UTF-8
       VC Keymap: fr-oss                  (was fr before)
      X11 Layout: fr
       X11 Model: pc105
     X11 Variant: oss
% sudo localectl set-x11-keymap fr pc105
% localectl
   System Locale: LANG=en_US.UTF-8
       VC Keymap: fr
      X11 Layout: fr
       X11 Model: pc105
% sudo localectl set-x11-keymap gb
% localectl
   System Locale: LANG=en_US.UTF-8
       VC Keymap: gb                     (was uk before)
      X11 Layout: gb
2013-11-18 20:35:52 -05:00
Zbigniew Jędrzejewski-Szmek
98fce79dea localed: use _cleanup_ 2013-11-18 20:35:52 -05:00
Karel Zak
4561be3a64 Remove duplicate includes 2013-11-18 20:28:55 -05:00
Shawn Landden
05d3a17623 use #pragma once instead of foo*foo define guards 2013-11-18 20:28:54 -05:00
Thomas Hindoe Paaboel Andersen
d5d217eae1 remove unused variables 2013-11-18 23:04:16 +01:00
Kay Sievers
f21326e604 bus: TIMESTAMP is optional kdbus metadata now, NAMES are always added 2013-11-18 01:30:57 +01:00
Shawn Landden
f0511bd7e3 core/socket: fix SO_REUSEPORT 2013-11-17 17:41:35 -05:00
Shawn Landden
e55001ebba core/socket: use _cleanup_free_ 2013-11-17 17:41:35 -05:00
Tom Gundersen
f882c247ad networkd: make all calls async 2013-11-17 23:12:27 +01:00
Tom Gundersen
8cd11a0f0f networkd: store netmask and mac address explicitly 2013-11-17 23:11:11 +01:00
Kay Sievers
16be43684f bus: CREDS and NAMES are optional kdbus metadata now 2013-11-17 22:35:58 +01:00
Sylvain Plantefeve
0571a6b0a9 catalog: add French translation 2013-11-17 11:56:19 -05:00