25 #include "dbus-misc.h"
26 #include "dbus-internals.h"
27 #include "dbus-string.h"
162 int *minor_version_p,
163 int *micro_version_p)
176 #ifdef DBUS_BUILD_TESTS
178 #ifndef DOXYGEN_SHOULD_SKIP_THIS
180 #include "dbus-test.h"
185 _dbus_misc_test (
void)
187 int major, minor, micro;
204 #define MAKE_VERSION(x, y, z) (((x) << 16) | ((y) << 8) | (z))
207 _dbus_assert (MAKE_VERSION (1, 0, 0) > MAKE_VERSION (0, 0, 0));
208 _dbus_assert (MAKE_VERSION (1, 1, 0) > MAKE_VERSION (1, 0, 0));
209 _dbus_assert (MAKE_VERSION (1, 1, 1) > MAKE_VERSION (1, 1, 0));
211 _dbus_assert (MAKE_VERSION (2, 0, 0) > MAKE_VERSION (1, 1, 1));
212 _dbus_assert (MAKE_VERSION (2, 1, 0) > MAKE_VERSION (1, 1, 1));
213 _dbus_assert (MAKE_VERSION (2, 1, 1) > MAKE_VERSION (1, 1, 1));
#define NULL
A null pointer, defined appropriately for C or C++.
dbus_bool_t _dbus_string_append_int(DBusString *str, long value)
Appends an integer to a DBusString.
#define _dbus_assert(condition)
Aborts with an error message if the condition is false.
#define DBUS_MAJOR_VERSION
The COMPILE TIME major version of libdbus, that is, the "X" in "X.Y.Z", as an integer literal...
void dbus_get_version(int *major_version_p, int *minor_version_p, int *micro_version_p)
Gets the DYNAMICALLY LINKED version of libdbus.
#define DBUS_MICRO_VERSION
The COMPILE TIME micro version of libdbus, that is, the "Z" in "X.Y.Z", as an integer literal...
dbus_bool_t _dbus_string_init(DBusString *str)
Initializes a string.
dbus_bool_t _dbus_get_local_machine_uuid_encoded(DBusString *uuid_str)
Gets the hex-encoded UUID of the machine this function is executed on.
#define DBUS_VERSION_STRING
The COMPILE TIME version of libdbus, as a string "X.Y.Z".
dbus_bool_t _dbus_string_equal_c_str(const DBusString *a, const char *c_str)
Checks whether a string is equal to a C string.
dbus_uint32_t dbus_bool_t
A boolean, valid values are TRUE and FALSE.
#define DBUS_MINOR_VERSION
The COMPILE TIME minor version of libdbus, that is, the "Y" in "X.Y.Z", as an integer literal...
dbus_bool_t _dbus_string_append_byte(DBusString *str, unsigned char byte)
Appends a single byte to the string, returning FALSE if not enough memory.
void _dbus_string_free(DBusString *str)
Frees a string created by _dbus_string_init().
#define TRUE
Expands to "1".
#define _dbus_assert_not_reached(explanation)
Aborts with an error message if called.
#define DBUS_VERSION
The COMPILE TIME version of libdbus, as a single integer that has 0 in the most significant byte...
char * dbus_get_local_machine_id(void)
Obtains the machine UUID of the machine this process is running on.
dbus_bool_t _dbus_string_steal_data(DBusString *str, char **data_return)
Like _dbus_string_get_data(), but removes the gotten data from the original string.