dbus/bus
Ralf Habacker d5e7e2794e Always assert that BUS_CONNECTION_DATA() returns non-NULL
Every DBusConnection in the dbus-daemon should have been through
bus_connections_setup_connection(), so we can assert that the
BusConnectionData has been attached to it. Having this assertion
is enough to hint to Coverity that it does not need to worry about
whether this pointer might be NULL.

In regression tests, we do work with a few fake client-side
DBusConnection instances in the same process; but it would be a
serious bug if we mixed those up with the ones processed by
dbus-daemon's real code, so the assertion is still valid.

This patch has been inspired by (and fixes) the following coverity scan issues:
CID 54846: Dereference null return value (NULL_RETURNS).
CID 54854: Dereference null return value (NULL_RETURNS).

Bug: https://bugs.freedesktop.org/show_bug.cgi?id=90021
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
[smcv: fixed -Wdeclaration-after-statement; more informative commit message]
Reviewed-by: Ralf Habacker <ralf.habacker@freenet.de>
2015-04-17 13:07:05 +01:00
..
systemd-user Optionally install systemd user units for a per-user bus 2015-02-24 11:15:37 +00:00
.gitignore Update .gitignore files 2015-02-03 15:40:01 +00:00
activation-exit-codes.h Bug 21161 - Update the FSF address 2009-07-14 15:39:47 -04:00
activation-helper-bin.c launch-helper: fix error code parsing 2013-10-09 10:51:39 +01:00
activation-helper.c launch-helper: fix error code parsing 2013-10-09 10:51:39 +01:00
activation-helper.h Bug 21161 - Update the FSF address 2009-07-14 15:39:47 -04:00
activation.c Capture all messages received or sent, and send them to monitors 2015-02-04 17:15:17 +00:00
activation.h CVE-2014-3477: deliver activation errors correctly, fixing Denial of Service 2014-06-05 14:36:17 +01:00
apparmor.c apparmor: Fix build failure with --disable-apparmor 2015-02-19 10:22:17 +00:00
apparmor.h Revert "Add DBus method to return the AA context of a connection" 2015-02-18 20:57:08 +00:00
bus.c Mediation of processes sending and receiving messages 2015-02-18 18:59:23 +00:00
bus.h Store AppArmor label of connecting processes 2015-02-18 17:04:05 +00:00
config-loader-expat.c Fixed gcc on windows limitation 2010-03-20 21:53:57 +01:00
config-parser-common.c Add apparmor element support to bus config parsing 2015-02-18 17:04:00 +00:00
config-parser-common.h Add apparmor element support to bus config parsing 2015-02-18 17:04:00 +00:00
config-parser-trivial.c tests to embedded tests: replaced in dbus-daemon 2013-06-28 12:13:28 +01:00
config-parser-trivial.h Merge branch 'dbus-1.2' 2010-06-22 17:25:20 +01:00
config-parser.c include_dir: skip processing on error (CID 54744) 2015-04-16 13:15:19 +01:00
config-parser.h Consistently include <config.h> in all C source files and never in header files. 2010-03-19 20:11:48 +01:00
connection.c Always assert that BUS_CONNECTION_DATA() returns non-NULL 2015-04-17 13:07:05 +01:00
connection.h Mediation of processes that acquire well-known names 2015-02-18 17:28:42 +00:00
dbus.service.in Add "Documentation=man:dbus-daemon(1)" line to systemd service 2014-04-28 15:42:11 +01:00
dbus.socket.in systemd: enable the dbus service unconditionally 2010-09-06 03:21:17 +02:00
desktop-file.c Fix dbus-daemon crash due to invalid service file 2013-06-12 13:42:00 +01:00
desktop-file.h Remove unused key-word of DBus .service file 2013-10-09 10:53:38 +01:00
dir-watch-default.c Fix warnings on Windows builds. 2010-04-14 08:26:40 +02:00
dir-watch-inotify.c inotify: make sure we set the close-on-exec flag 2014-09-23 19:25:55 +01:00
dir-watch-kqueue.c build: include dbus-sysdeps-unix.h for _dbus_fd_set_close_on_exec 2014-10-28 17:10:52 +00:00
dir-watch.h Clean up inotify watch handling 2010-02-01 16:22:56 -05:00
dispatch.c Fix assorted compiler warnings on Windows. 2015-03-24 08:27:09 +01:00
dispatch.h Bug 21161 - Update the FSF address 2009-07-14 15:39:47 -04:00
driver.c Improve diagnostics when UpdateActivationEnvironment calls are rejected 2015-03-05 13:09:07 +00:00
driver.h Hardening: reject UpdateActivationEnvironment on non-canonical path 2015-01-01 23:32:16 +00:00
example-session-disable-stats.conf.in config: add examples to show how to enable/disable the Stats interface 2014-10-01 16:38:40 +01:00
example-system-enable-stats.conf.in config: add examples to show how to enable/disable the Stats interface 2014-10-01 16:38:40 +01:00
expirelist.c tests to embedded tests: replaced in dbus-daemon 2013-06-28 12:13:28 +01:00
expirelist.h Bug 21161 - Update the FSF address 2009-07-14 15:39:47 -04:00
main.c Rename _dbus_full_duplex_pipe() to more descriptive name _dbus_socketpair(). 2015-03-24 08:13:36 +01:00
Makefile.am Optionally install systemd user units for a per-user bus 2015-02-24 11:15:37 +00:00
messagebus-config.in Applied patches from cygwin port. 2010-08-10 08:25:24 +02:00
messagebus.in Fix use of $servicename in status 2010-07-09 11:52:59 -04:00
org.freedesktop.dbus-session.plist.in 10.4 is old so set more sensible launchd defaults. 2010-12-09 08:20:07 +01:00
policy.c tests to embedded tests: replaced in dbus-daemon 2013-06-28 12:13:28 +01:00
policy.h tests to embedded tests: replaced in dbus-daemon 2013-06-28 12:13:28 +01:00
rc.messagebus.in [legacy init script] Fix the use of $servicename 2010-04-23 12:02:19 -04:00
selinux.c selinux: avoid leaking on systems where va_start allocates memory 2015-01-06 22:12:27 +00:00
selinux.h Fix compilation in --disable-selinux case 2010-02-02 15:04:58 -05:00
services.c Mediation of processes that acquire well-known names 2015-02-18 17:28:42 +00:00
services.h Bug 21161 - Update the FSF address 2009-07-14 15:39:47 -04:00
session.conf.in Remove <apparmor/> from default system.conf, session.conf 2015-02-19 16:46:21 +00:00
signals.c Trivial -Wsign-compare fixes. 2015-03-04 12:18:42 +01:00
signals.h Mediation of processes eavesdropping 2015-02-18 18:59:46 +00:00
stats.c Merge branch 'dbus-1.8' and prepare 1.9.6 2015-01-01 23:48:13 +00:00
stats.h Implement GetAllMatchRules on the Stats interface 2014-09-25 12:59:50 +01:00
system.conf.in Remove <apparmor/> from default system.conf, session.conf 2015-02-19 16:46:21 +00:00
test-launch-helper.c Export dbus_setenv() as a utility function 2013-08-23 11:40:50 +01:00
test-main.c test-bus, test-dbus: close any inherited fds from caller 2014-10-24 18:48:18 +02:00
test-system.c tests to embedded tests: replaced in dbus-daemon 2013-06-28 12:13:28 +01:00
test.c tests to embedded tests: replaced in dbus-daemon 2013-06-28 12:13:28 +01:00
test.h tests to embedded tests: replaced in dbus-daemon 2013-06-28 12:13:28 +01:00
utils.c Bug 21161 - Update the FSF address 2009-07-14 15:39:47 -04:00
utils.h Bug 21161 - Update the FSF address 2009-07-14 15:39:47 -04:00