* Copyright (C) 2003 CodeFactory AB
* Copyright (C) 2003 Red Hat, Inc.
*
- * Licensed under the Academic Free License version 1.2
+ * Licensed under the Academic Free License version 2.0
*
* 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
#include "dbus-transport-unix.h"
#include "dbus-connection-internal.h"
#include "dbus-hash.h"
+#include "dbus-string.h"
#ifdef DBUS_BUILD_TESTS
dbus_free (server);
}
-static dbus_bool_t
-debug_handle_watch (DBusServer *server,
- DBusWatch *watch,
- unsigned int flags)
-{
-
- return TRUE;
-}
-
static void
debug_disconnect (DBusServer *server)
{
static DBusServerVTable debug_vtable = {
debug_finalize,
- debug_handle_watch,
debug_disconnect
};
DBusString address;
_DBUS_ASSERT_ERROR_IS_CLEAR (error);
+
+ if (server_pipe_hash == NULL)
+ {
+ dbus_set_error (error, DBUS_ERROR_NO_SERVER, NULL);
+ return NULL;
+ }
server = _dbus_hash_table_lookup_string (server_pipe_hash,
server_name);
if (server == NULL ||
((DBusServerDebugPipe*)server)->disconnected)
{
- dbus_set_error (error, DBUS_ERROR_BAD_ADDRESS, NULL);
+ dbus_set_error (error, DBUS_ERROR_NO_SERVER, NULL);
return NULL;
}