+2003-11-26 Mikael Hallendal <micke@imendio.com>
+
+ * bus/*.[ch]:
+ * dbus/*.[ch]:
+ * glib/*.[ch]: Made ref functions return the pointer
+
2003-11-25 Zack Rusin <zack@kde.org>
* qt/integrator.h, qt/integrator.cpp: Adding handling of DBusServer,
_dbus_wait_for_memory ();
}
-static void
+static BusPendingActivation *
bus_pending_activation_ref (BusPendingActivation *pending_activation)
{
_dbus_assert (pending_activation->refcount > 0);
pending_activation->refcount += 1;
+
+ return pending_activation;
}
static void
return NULL;
}
-void
+BusActivation *
bus_activation_ref (BusActivation *activation)
{
_dbus_assert (activation->refcount > 0);
activation->refcount += 1;
+
+ return activation;
}
void
const DBusString *address,
DBusList **directories,
DBusError *error);
-void bus_activation_ref (BusActivation *activation);
+BusActivation* bus_activation_ref (BusActivation *activation);
void bus_activation_unref (BusActivation *activation);
dbus_bool_t bus_activation_activate_service (BusActivation *activation,
DBusConnection *connection,
}
}
-void
+BusContext *
bus_context_ref (BusContext *context)
{
_dbus_assert (context->refcount > 0);
context->refcount += 1;
+
+ return context;
}
void
int print_pid_fd,
DBusError *error);
void bus_context_shutdown (BusContext *context);
-void bus_context_ref (BusContext *context);
+BusContext* bus_context_ref (BusContext *context);
void bus_context_unref (BusContext *context);
const char* bus_context_get_type (BusContext *context);
const char* bus_context_get_address (BusContext *context);
return parser;
}
-void
+BusConfigParser *
bus_config_parser_ref (BusConfigParser *parser)
{
_dbus_assert (parser->refcount > 0);
parser->refcount += 1;
+
+ return parser;
}
void
BusConfigParser* bus_config_parser_new (const DBusString *basedir,
dbus_bool_t is_toplevel);
-void bus_config_parser_ref (BusConfigParser *parser);
+BusConfigParser* bus_config_parser_ref (BusConfigParser *parser);
void bus_config_parser_unref (BusConfigParser *parser);
dbus_bool_t bus_config_parser_check_doctype (BusConfigParser *parser,
const char *doctype,
return NULL;
}
-void
+BusConnections *
bus_connections_ref (BusConnections *connections)
{
_dbus_assert (connections->refcount > 0);
connections->refcount += 1;
+
+ return connections;
}
void
BusConnections* bus_connections_new (BusContext *context);
-void bus_connections_ref (BusConnections *connections);
+BusConnections* bus_connections_ref (BusConnections *connections);
void bus_connections_unref (BusConnections *connections);
dbus_bool_t bus_connections_setup_connection (BusConnections *connections,
DBusConnection *connection);
return rule;
}
-void
+BusPolicyRule *
bus_policy_rule_ref (BusPolicyRule *rule)
{
_dbus_assert (rule->refcount > 0);
rule->refcount += 1;
+
+ return rule;
}
void
return NULL;
}
-void
+BusPolicy *
bus_policy_ref (BusPolicy *policy)
{
_dbus_assert (policy->refcount > 0);
policy->refcount += 1;
+
+ return policy;
}
void
return policy;
}
-void
+BusClientPolicy *
bus_client_policy_ref (BusClientPolicy *policy)
{
_dbus_assert (policy->refcount > 0);
policy->refcount += 1;
+
+ return policy;
}
static void
BusPolicyRule* bus_policy_rule_new (BusPolicyRuleType type,
dbus_bool_t allow);
-void bus_policy_rule_ref (BusPolicyRule *rule);
+BusPolicyRule* bus_policy_rule_ref (BusPolicyRule *rule);
void bus_policy_rule_unref (BusPolicyRule *rule);
BusPolicy* bus_policy_new (void);
-void bus_policy_ref (BusPolicy *policy);
+BusPolicy* bus_policy_ref (BusPolicy *policy);
void bus_policy_unref (BusPolicy *policy);
BusClientPolicy* bus_policy_create_client_policy (BusPolicy *policy,
DBusConnection *connection,
BusPolicy *to_absorb);
BusClientPolicy* bus_client_policy_new (void);
-void bus_client_policy_ref (BusClientPolicy *policy);
+BusClientPolicy* bus_client_policy_ref (BusClientPolicy *policy);
void bus_client_policy_unref (BusClientPolicy *policy);
dbus_bool_t bus_client_policy_check_can_send (BusClientPolicy *policy,
BusRegistry *registry,
return NULL;
}
-void
+BusRegistry *
bus_registry_ref (BusRegistry *registry)
{
_dbus_assert (registry->refcount > 0);
registry->refcount += 1;
+
+ return registry;
}
void
return TRUE;
}
-void
+BusService *
bus_service_ref (BusService *service)
{
_dbus_assert (service->refcount > 0);
service->refcount += 1;
+
+ return service;
}
void
void *data);
BusRegistry* bus_registry_new (BusContext *context);
-void bus_registry_ref (BusRegistry *registry);
+BusRegistry* bus_registry_ref (BusRegistry *registry);
void bus_registry_unref (BusRegistry *registry);
BusService* bus_registry_lookup (BusRegistry *registry,
const DBusString *service_name);
BusTransaction *transaction,
DBusError *error);
-void bus_service_ref (BusService *service);
+BusService* bus_service_ref (BusService *service);
void bus_service_unref (BusService *service);
dbus_bool_t bus_service_add_owner (BusService *service,
DBusConnection *owner,
return rule;
}
-void
+BusMatchRule *
bus_match_rule_ref (BusMatchRule *rule)
{
_dbus_assert (rule->refcount > 0);
rule->refcount += 1;
+
+ return rule;
}
void
return matchmaker;
}
-void
+BusMatchmaker *
bus_matchmaker_ref (BusMatchmaker *matchmaker)
{
_dbus_assert (matchmaker->refcount > 0);
matchmaker->refcount += 1;
+
+ return matchmaker;
}
void
} BusMatchFlags;
BusMatchRule* bus_match_rule_new (DBusConnection *matches_go_to);
-void bus_match_rule_ref (BusMatchRule *rule);
+BusMatchRule* bus_match_rule_ref (BusMatchRule *rule);
void bus_match_rule_unref (BusMatchRule *rule);
dbus_bool_t bus_match_rule_set_message_type (BusMatchRule *rule,
DBusError *error);
BusMatchmaker* bus_matchmaker_new (void);
-void bus_matchmaker_ref (BusMatchmaker *matchmaker);
+BusMatchmaker* bus_matchmaker_ref (BusMatchmaker *matchmaker);
void bus_matchmaker_unref (BusMatchmaker *matchmaker);
dbus_bool_t bus_matchmaker_add_rule (BusMatchmaker *matchmaker,
* Increments the refcount of an auth object.
*
* @param auth the auth conversation
+ * @returns the auth conversation
*/
-void
+DBusAuth *
_dbus_auth_ref (DBusAuth *auth)
{
_dbus_assert (auth != NULL);
auth->refcount += 1;
+
+ return auth;
}
/**
DBusAuth* _dbus_auth_server_new (void);
DBusAuth* _dbus_auth_client_new (void);
-void _dbus_auth_ref (DBusAuth *auth);
+DBusAuth* _dbus_auth_ref (DBusAuth *auth);
void _dbus_auth_unref (DBusAuth *auth);
dbus_bool_t _dbus_auth_set_mechanisms (DBusAuth *auth,
const char **mechanisms);
void _dbus_connection_lock (DBusConnection *connection);
void _dbus_connection_unlock (DBusConnection *connection);
-void _dbus_connection_ref_unlocked (DBusConnection *connection);
+DBusConnection * _dbus_connection_ref_unlocked (DBusConnection *connection);
void _dbus_connection_unref_unlocked (DBusConnection *connection);
dbus_bool_t _dbus_connection_queue_received_message (DBusConnection *connection,
DBusMessage *message);
DBusDispatchStatus new_status);
static void _dbus_connection_last_unref (DBusConnection *connection);
-static void
+static DBusMessageFilter *
_dbus_message_filter_ref (DBusMessageFilter *filter)
{
_dbus_assert (filter->refcount.value > 0);
_dbus_atomic_inc (&filter->refcount);
+
+ return filter;
}
static void
* Requires that the caller already holds the connection lock.
*
* @param connection the connection.
+ * @returns the connection.
*/
-void
+DBusConnection *
_dbus_connection_ref_unlocked (DBusConnection *connection)
{
#ifdef DBUS_HAVE_ATOMIC_INT
_dbus_assert (connection->refcount.value > 0);
connection->refcount.value += 1;
#endif
+
+ return connection;
}
/**
* Increments the reference count of a DBusConnection.
*
* @param connection the connection.
+ * @returns the connection.
*/
-void
+DBusConnection *
dbus_connection_ref (DBusConnection *connection)
{
- _dbus_return_if_fail (connection != NULL);
+ _dbus_return_val_if_fail (connection != NULL, NULL);
/* The connection lock is better than the global
* lock in the atomic increment fallback
connection->refcount.value += 1;
CONNECTION_UNLOCK (connection);
#endif
+
+ return connection;
}
static void
DBusConnection* dbus_connection_open (const char *address,
DBusError *error);
-void dbus_connection_ref (DBusConnection *connection);
+DBusConnection* dbus_connection_ref (DBusConnection *connection);
void dbus_connection_unref (DBusConnection *connection);
void dbus_connection_disconnect (DBusConnection *connection);
dbus_bool_t dbus_connection_get_is_connected (DBusConnection *connection);
* Increments the reference count for a hash table.
*
* @param table the hash table to add a reference to.
+ * @returns the hash table.
*/
-void
+DBusHashTable *
_dbus_hash_table_ref (DBusHashTable *table)
{
table->refcount += 1;
+
+ return table;
}
/**
DBusHashTable* _dbus_hash_table_new (DBusHashType type,
DBusFreeFunction key_free_function,
DBusFreeFunction value_free_function);
-void _dbus_hash_table_ref (DBusHashTable *table);
+DBusHashTable* _dbus_hash_table_ref (DBusHashTable *table);
void _dbus_hash_table_unref (DBusHashTable *table);
void _dbus_hash_iter_init (DBusHashTable *table,
DBusHashIter *iter);
* Increments reference count of the keyring
*
* @param keyring the keyring
+ * @returns the keyring
*/
-void
+DBusKeyring *
_dbus_keyring_ref (DBusKeyring *keyring)
{
keyring->refcount += 1;
+
+ return keyring;
}
/**
DBusKeyring* _dbus_keyring_new_homedir (const DBusString *username,
const DBusString *context,
DBusError *error);
-void _dbus_keyring_ref (DBusKeyring *keyring);
+DBusKeyring* _dbus_keyring_ref (DBusKeyring *keyring);
void _dbus_keyring_unref (DBusKeyring *keyring);
dbus_bool_t _dbus_keyring_validate_context (const DBusString *context);
int _dbus_keyring_get_best_key (DBusKeyring *keyring,
return cb;
}
-static void
+static Callback *
callback_ref (Callback *cb)
{
_dbus_assert (cb->refcount > 0);
cb->refcount += 1;
+
+ return cb;
}
static void
return loop;
}
-void
+DBusLoop *
_dbus_loop_ref (DBusLoop *loop)
{
_dbus_assert (loop != NULL);
_dbus_assert (loop->refcount > 0);
loop->refcount += 1;
+
+ return loop;
}
void
void *data);
DBusLoop* _dbus_loop_new (void);
-void _dbus_loop_ref (DBusLoop *loop);
+DBusLoop* _dbus_loop_ref (DBusLoop *loop);
void _dbus_loop_unref (DBusLoop *loop);
dbus_bool_t _dbus_loop_add_watch (DBusLoop *loop,
DBusWatch *watch,
* Increments the reference count on a message handler.
*
* @param handler the handler
+ * @returns the handler
*/
-void
+DBusMessageHandler *
dbus_message_handler_ref (DBusMessageHandler *handler)
{
_dbus_return_if_fail (handler != NULL);
_dbus_atomic_inc (&handler->refcount);
+
+ return handler;
}
/**
DBusFreeFunction free_user_data);
-void dbus_message_handler_ref (DBusMessageHandler *handler);
+DBusMessageHandler* dbus_message_handler_ref (DBusMessageHandler *handler);
void dbus_message_handler_unref (DBusMessageHandler *handler);
DBusList **link_return);
DBusMessageLoader* _dbus_message_loader_new (void);
-void _dbus_message_loader_ref (DBusMessageLoader *loader);
+DBusMessageLoader* _dbus_message_loader_ref (DBusMessageLoader *loader);
void _dbus_message_loader_unref (DBusMessageLoader *loader);
void _dbus_message_loader_get_buffer (DBusMessageLoader *loader,
* Increments the reference count of a DBusMessage.
*
* @param message The message
+ * @returns the message
* @see dbus_message_unref
*/
-void
+DBusMessage *
dbus_message_ref (DBusMessage *message)
{
dbus_int32_t old_refcount;
- _dbus_return_if_fail (message != NULL);
+ _dbus_return_val_if_fail (message != NULL, NULL);
old_refcount = _dbus_atomic_inc (&message->refcount);
_dbus_assert (old_refcount >= 1);
+
+ return message;
}
static void
* Increments the reference count of the loader.
*
* @param loader the loader.
+ * @returns the loader
*/
-void
+DBusMessageLoader *
_dbus_message_loader_ref (DBusMessageLoader *loader)
{
loader->refcount += 1;
+
+ return loader;
}
/**
const char *error_name,
const char *error_message);
-DBusMessage *dbus_message_copy (const DBusMessage *message);
+DBusMessage* dbus_message_copy (const DBusMessage *message);
-void dbus_message_ref (DBusMessage *message);
+DBusMessage* dbus_message_ref (DBusMessage *message);
void dbus_message_unref (DBusMessage *message);
int dbus_message_get_type (DBusMessage *message);
dbus_bool_t dbus_message_set_path (DBusMessage *message,
static DBusObjectSubtree* _dbus_object_subtree_new (const char *name,
const DBusObjectPathVTable *vtable,
void *user_data);
-static void _dbus_object_subtree_ref (DBusObjectSubtree *subtree);
+static DBusObjectSubtree* _dbus_object_subtree_ref (DBusObjectSubtree *subtree);
static void _dbus_object_subtree_unref (DBusObjectSubtree *subtree);
/**
/**
* Increment the reference count
* @param tree the object tree
+ * @returns the object tree
*/
-void
+DBusObjectTree *
_dbus_object_tree_ref (DBusObjectTree *tree)
{
_dbus_assert (tree->refcount > 0);
tree->refcount += 1;
+
+ return tree;
}
/**
return NULL;
}
-static void
+static DBusObjectSubtree *
_dbus_object_subtree_ref (DBusObjectSubtree *subtree)
{
_dbus_assert (subtree->refcount.value > 0);
_dbus_atomic_inc (&subtree->refcount);
+
+ return subtree;
}
static void
typedef struct DBusObjectTree DBusObjectTree;
DBusObjectTree* _dbus_object_tree_new (DBusConnection *connection);
-void _dbus_object_tree_ref (DBusObjectTree *tree);
+DBusObjectTree* _dbus_object_tree_ref (DBusObjectTree *tree);
void _dbus_object_tree_unref (DBusObjectTree *tree);
dbus_bool_t _dbus_object_tree_register (DBusObjectTree *tree,
* Increments the reference count on a pending call.
*
* @param pending the pending call object
+ * @returns the pending call object
*/
-void
+DBusPendingCall *
dbus_pending_call_ref (DBusPendingCall *pending)
{
_dbus_return_if_fail (pending != NULL);
_dbus_atomic_inc (&pending->refcount);
+
+ return pending;
}
/**
DBUS_BEGIN_DECLS;
-void dbus_pending_call_ref (DBusPendingCall *pending);
+DBusPendingCall* dbus_pending_call_ref (DBusPendingCall *pending);
void dbus_pending_call_unref (DBusPendingCall *pending);
dbus_bool_t dbus_pending_call_set_notify (DBusPendingCall *pending,
DBusPendingCallNotifyFunction function,
* Increments refcount of the counter
*
* @param counter the counter
+ * @returns the counter
*/
-void
+DBusCounter *
_dbus_counter_ref (DBusCounter *counter)
{
_dbus_assert (counter->refcount > 0);
counter->refcount += 1;
+
+ return counter;
}
/**
void *user_data);
DBusCounter* _dbus_counter_new (void);
-void _dbus_counter_ref (DBusCounter *counter);
+DBusCounter* _dbus_counter_ref (DBusCounter *counter);
void _dbus_counter_unref (DBusCounter *counter);
void _dbus_counter_adjust (DBusCounter *counter,
long delta);
* Increments the reference count of a DBusServer.
*
* @param server the server.
+ * @returns the server
*/
-void
+DBusServer *
dbus_server_ref (DBusServer *server)
{
_dbus_return_if_fail (server != NULL);
server->refcount += 1;
+
+ return server;
}
/**
DBusServer* dbus_server_listen (const char *address,
DBusError *error);
-void dbus_server_ref (DBusServer *server);
+DBusServer* dbus_server_ref (DBusServer *server);
void dbus_server_unref (DBusServer *server);
void dbus_server_disconnect (DBusServer *server);
dbus_bool_t dbus_server_get_is_connected (DBusServer *server);
* Increment the reference count on the babysitter object.
*
* @param sitter the babysitter
+ * @returns the babysitter
*/
-void
+DBusBabysitter *
_dbus_babysitter_ref (DBusBabysitter *sitter)
{
_dbus_assert (sitter != NULL);
_dbus_assert (sitter->refcount > 0);
sitter->refcount += 1;
+
+ return sitter;
}
/**
DBusSpawnChildSetupFunc child_setup,
void *user_data,
DBusError *error);
-void _dbus_babysitter_ref (DBusBabysitter *sitter);
+DBusBabysitter* _dbus_babysitter_ref (DBusBabysitter *sitter);
void _dbus_babysitter_unref (DBusBabysitter *sitter);
void _dbus_babysitter_kill_child (DBusBabysitter *sitter);
dbus_bool_t _dbus_babysitter_get_child_exited (DBusBabysitter *sitter);
* 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;
}
/**
DBusTimeoutHandler handler,
void *data,
DBusFreeFunction free_data_function);
-void _dbus_timeout_ref (DBusTimeout *timeout);
+DBusTimeout* _dbus_timeout_ref (DBusTimeout *timeout);
void _dbus_timeout_unref (DBusTimeout *timeout);
void _dbus_timeout_set_interval (DBusTimeout *timeout,
int interval);
* Increments the reference count for the transport.
*
* @param transport the transport.
+ * @returns the transport.
*/
-void
+DBusTransport *
_dbus_transport_ref (DBusTransport *transport)
{
_dbus_assert (transport->refcount > 0);
transport->refcount += 1;
+
+ return transport;
}
/**
DBusTransport* _dbus_transport_open (const char *address,
DBusError *error);
-void _dbus_transport_ref (DBusTransport *transport);
+DBusTransport* _dbus_transport_ref (DBusTransport *transport);
void _dbus_transport_unref (DBusTransport *transport);
void _dbus_transport_disconnect (DBusTransport *transport);
dbus_bool_t _dbus_transport_get_is_connected (DBusTransport *transport);
/**
* Increments refcount of user database.
* @param db the database
+ * @returns the database
*/
-void
+DBusUserDatabase *
_dbus_user_database_ref (DBusUserDatabase *db)
{
_dbus_assert (db->refcount > 0);
db->refcount += 1;
+
+ return db;
}
/**
typedef struct DBusUserDatabase DBusUserDatabase;
DBusUserDatabase* _dbus_user_database_new (void);
-void _dbus_user_database_ref (DBusUserDatabase *db);
+DBusUserDatabase* _dbus_user_database_ref (DBusUserDatabase *db);
void _dbus_user_database_unref (DBusUserDatabase *db);
dbus_bool_t _dbus_user_database_get_groups (DBusUserDatabase *db,
dbus_uid_t uid,
* Increments the reference count of a DBusWatch object.
*
* @param watch the watch object.
+ * @returns the watch object.
*/
-void
+DBusWatch *
_dbus_watch_ref (DBusWatch *watch)
{
watch->refcount += 1;
+
+ return watch;
}
/**
DBusWatchHandler handler,
void *data,
DBusFreeFunction free_data_function);
-void _dbus_watch_ref (DBusWatch *watch);
+DBusWatch* _dbus_watch_ref (DBusWatch *watch);
void _dbus_watch_unref (DBusWatch *watch);
void _dbus_watch_invalidate (DBusWatch *watch);
void _dbus_watch_sanitize_condition (DBusWatch *watch,
ArgDirection direction;
};
-void
+BaseInfo *
base_info_ref (BaseInfo *info)
{
g_return_if_fail (info != NULL);
g_return_if_fail (info->refcount > 0);
info->refcount += 1;
+
+ return info;
}
static void
return info;
}
-void
+NodeInfo *
node_info_ref (NodeInfo *info)
{
info->base.refcount += 1;
+
+ return info;
}
void
return info;
}
-void
+InterfaceInfo *
interface_info_ref (InterfaceInfo *info)
{
info->base.refcount += 1;
+
+ return info;
}
void
return info;
}
-void
+MethodInfo *
method_info_ref (MethodInfo *info)
{
info->base.refcount += 1;
+
+ return info;
}
void
return info;
}
-void
+SignalInfo *
signal_info_ref (SignalInfo *info)
{
info->base.refcount += 1;
+
+ return info;
}
void
return info;
}
-void
+ArgInfo *
arg_info_ref (ArgInfo *info)
{
info->base.refcount += 1;
+
+ return info;
}
void
} InfoType;
-void base_info_ref (BaseInfo *info);
+BaseInfo* base_info_ref (BaseInfo *info);
void base_info_unref (BaseInfo *info);
InfoType base_info_get_type (BaseInfo *info);
const char* base_info_get_name (BaseInfo *info);
NodeInfo* node_info_new (const char *name);
-void node_info_ref (NodeInfo *info);
+NodeInfo* node_info_ref (NodeInfo *info);
void node_info_unref (NodeInfo *info);
const char* node_info_get_name (NodeInfo *info);
GSList* node_info_get_interfaces (NodeInfo *info);
NodeInfo *child);
InterfaceInfo* interface_info_new (const char *name);
-void interface_info_ref (InterfaceInfo *info);
+InterfaceInfo* interface_info_ref (InterfaceInfo *info);
void interface_info_unref (InterfaceInfo *info);
const char* interface_info_get_name (InterfaceInfo *info);
GSList* interface_info_get_methods (InterfaceInfo *info);
SignalInfo *signal);
MethodInfo* method_info_new (const char *name);
-void method_info_ref (MethodInfo *info);
+MethodInfo* method_info_ref (MethodInfo *info);
void method_info_unref (MethodInfo *info);
const char* method_info_get_name (MethodInfo *info);
ArgInfo *arg);
SignalInfo* signal_info_new (const char *name);
-void signal_info_ref (SignalInfo *info);
+SignalInfo* signal_info_ref (SignalInfo *info);
void signal_info_unref (SignalInfo *info);
const char* signal_info_get_name (SignalInfo *info);
ArgInfo* arg_info_new (const char *name,
ArgDirection direction,
int type);
-void arg_info_ref (ArgInfo *info);
+ArgInfo* arg_info_ref (ArgInfo *info);
void arg_info_unref (ArgInfo *info);
const char* arg_info_get_name (ArgInfo *info);
int arg_info_get_type (ArgInfo *info);
return watch_fd;
}
-static void
+static WatchFD *
watch_fd_ref (WatchFD *watch_fd)
{
watch_fd->refcount += 1;
+
+ return watch_fd;
}
static void
return parser;
}
-void
+Parser *
parser_ref (Parser *parser)
{
parser->refcount += 1;
+
+ return parser;
}
void
typedef struct Parser Parser;
Parser* parser_new (void);
-void parser_ref (Parser *parser);
+Parser* parser_ref (Parser *parser);
void parser_unref (Parser *parser);
gboolean parser_check_doctype (Parser *parser,
const char *doctype,
};
-static void dbus_gproxy_manager_ref (DBusGProxyManager *manager);
+static DBusGProxyManager *dbus_gproxy_manager_ref (DBusGProxyManager *manager);
static DBusHandlerResult dbus_gproxy_manager_filter (DBusConnection *connection,
DBusMessage *message,
void *user_data);
return manager;
}
-static void
+static DBusGProxyManager *
dbus_gproxy_manager_ref (DBusGProxyManager *manager)
{
g_assert (manager != NULL);
manager->refcount += 1;
UNLOCK_MANAGER (manager);
+
+ return manager;
}
static void