Commit graph

8 commits

Author SHA1 Message Date
Simon McVittie
7959d90719 Add missing function attributes suggested by clang (but not by gcc)
clang is a little more enthusiastic about suggesting these.

Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
2016-10-13 22:44:13 +01:00
Thomas Zimmermann
5350b54de7 Fix warnings from compiler option '-Wsuggest-attribute=noreturn'
This patch fixes warnings from '-Wsuggest-attribute=noreturn'. We cannot
enable it unconditionally as it would break libtool.

Signed-off-by: Thomas Zimmermann <tdz@users.sourceforge.net>
2016-10-10 15:11:24 +01:00
Simon McVittie
71c11a9e48 dbus-launch: use libdbus to read the UUID
As a side benefit, this means that dbus-launch now understands
/etc/machine-id and not just /var/lib/dbus/machine-id.

Since machine_uuid comes out of libdbus allocated with dbus_malloc,
to avoid having to copy it from malloc-allocated to
dbus_malloc-allocated storage, it makes sense to change it to be
consistently dbus_malloc-allocated (particularly now that Bug #83115
has made use of internal symbols relatively painless). However, I'm
deliberately not changing the allocation model of any other strings
in dbus-launch right now; that's a larger yak-shaving exercise.
2015-02-24 11:16:13 +00:00
Marcus Brinkmann
dbecdeabb2 Consistently include <config.h> in all C source files and never in header files. 2010-03-19 20:11:48 +01:00
Tobias Mueller
5baf2f856a Bug 21161 - Update the FSF address
No comment.

Signed-off-by: Colin Walters <walters@verbum.org>
2009-07-10 19:32:38 -04:00
Havoc Pennington
d012387afe 2007-07-13 Havoc Pennington <hp@redhat.com>
* Add indent-tabs-mode: nil to all file headers.
2007-07-14 02:44:01 +00:00
Havoc Pennington
10fe37f582 2006-10-01 Havoc Pennington <hp@redhat.com>
* tools/dbus-launch.c (print_variables): if no syntax is given,
	don't print something that's sort-of-half-sh-syntax, just print
	a plain key-value pairs thing.

	* tools/dbus-launch-x11.c: use machine ID rather than hostname for
	the local machine representation (but still have the hostname in
	the display). Remove the hostname from the display if it is
	localhost. Change session files to be named
	~/.dbus/session-bus/machine-display. Change X atoms to be
	underscore-prefixed so nobody whines about ICCCM compliance.
	Otherwise name them the same as the env variables.
	Change session file format to include key-value pairs and an
	explanatory comment. Keys are the same as the env variables.
	(set_address_in_x11): X property format can't depend on
	sizeof(pid_t) on a particular machine, fix to always be 32 bits

	* tools/dbus-launch.c: make --autolaunch take a machine id
	argument. If --autolaunch is used with a program to run, complain
	for now (but add a FIXME). Also, don't look for existing bus if
	there's a program to run (but add a FIXME).

	* dbus/dbus-sysdeps-unix.c (_dbus_get_autolaunch_address): pass
	machine uuid to dbus-launch (avoids linking dbus-launch to libdbus
	just to get this, and avoids duplicating uuid-reading code).

	* tools/dbus-launch.1: clarify various things
2006-10-01 20:05:39 +00:00
Thiago Macieira
f6fa010403 * configure.in: add DBUS_BINDIR as a #define to C source code.
* tools/dbus-launch.c
	* tools/dbus-launch.h
	* tools/dbus-launch-x11.c:
	* tools/dbus-launch.1: Add the --autolaunch option to
	dbus-launch, which makes it scan for an existing session
	started with --autolaunch. With that option, it also creates
	an X11 window and saves the bus address and PID to it.

	* dbus/dbus-sysdeps.h:
	* dbus/dbus-sysdeps-unix.c (_dbus_get_autolaunch_address): Add
	a function that runs "dbus-launch --autolaunch" to retrieve
	the running D-Bus session address (or start one if none was running)

	* dbus/dbus-transport.c: Add the handler for the "autolaunch:"
        address protocol, which tries to get the running session from
        dbus-launch.

	* dbus/dbus-bus.c:
	* dbus/dbus-internals.h: Make "autolaunch:" be the default
	D-Bus session bus address.

	* dbus/dbus-connection.c: Fix horrible typo in error message.
2006-09-30 19:38:34 +00:00