*
* Copyright (C) 2003 CodeFactory AB
*
- * Licensed under the Academic Free License version 1.2
+ * Licensed under the Academic Free License version 2.1
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* @{
*/
+/**
+ * Internals of DBusTimeout
+ */
struct DBusTimeout
{
int refcount; /**< Reference count */
DBusTimeout *timeout;
timeout = dbus_new0 (DBusTimeout, 1);
+ if (timeout == NULL)
+ return NULL;
+
timeout->refcount = 1;
timeout->interval = interval;
* Increments the reference count of a DBusTimeout object.
*
* @param timeout the timeout object.
+ * @returns the timeout object.
*/
-void
+DBusTimeout *
_dbus_timeout_ref (DBusTimeout *timeout)
{
timeout->refcount += 1;
+
+ return timeout;
}
/**
* only used in the message bus daemon implementation.
*
* @param timeout the timeout
- * @param interval the new interval
+ * @param enabled #TRUE if timeout should be enabled.
*/
void
_dbus_timeout_set_enabled (DBusTimeout *timeout,