summaryrefslogtreecommitdiff
path: root/bus/policy.h
diff options
context:
space:
mode:
authorHavoc Pennington <hp@redhat.com>2003-03-20 07:57:39 +0000
committerHavoc Pennington <hp@redhat.com>2003-03-20 07:57:39 +0000
commit056d76d809dc341b0dce160d3f79062604565c77 (patch)
tree1c0518c56526b71f8c4e77b97bb1b6e504339b55 /bus/policy.h
parenta284a148e40551a2e6e5d0e54c2e04d2b679aaad (diff)
2003-03-20 Havoc Pennington <hp@pobox.com>
* bus/connection.c (bus_connection_send_oom_error): assert that message has a sender (connection_execute_transaction): ditto (bus_connection_preallocate_oom_error): fix to set the sender, and set recipient to the destination service, not the bus driver * bus/policy.c: hacking * dbus/dbus-message.c (dbus_message_service_is): new function (dbus_message_sender_is): new
Diffstat (limited to 'bus/policy.h')
-rw-r--r--bus/policy.h31
1 files changed, 17 insertions, 14 deletions
diff --git a/bus/policy.h b/bus/policy.h
index f146c528..00d60baa 100644
--- a/bus/policy.h
+++ b/bus/policy.h
@@ -25,6 +25,7 @@
#define BUS_POLICY_H
#include <dbus/dbus.h>
+#include <dbus/dbus-string.h>
#include "bus.h"
typedef struct BusPolicy BusPolicy;
@@ -32,9 +33,9 @@ typedef struct BusPolicyRule BusPolicyRule;
typedef enum
{
- DBUS_POLICY_RULE_SEND,
- DBUS_POLICY_RULE_RECEIVE,
- DBUS_POLICY_RULE_OWN
+ BUS_POLICY_RULE_SEND,
+ BUS_POLICY_RULE_RECEIVE,
+ BUS_POLICY_RULE_OWN
} BusPolicyRuleType;
struct BusPolicyRule
@@ -76,17 +77,19 @@ void bus_policy_rule_ref (BusPolicyRule *rule);
void bus_policy_rule_unref (BusPolicyRule *rule);
BusPolicy* bus_policy_new (void);
-void bus_policy_ref (BusPolicy *policy);
-void bus_policy_unref (BusPolicy *policy);
-dbus_bool_t bus_policy_check_can_send (BusPolicy *policy,
- DBusConnection *sender,
- DBusMessage *message);
-dbus_bool_t bus_policy_check_can_receive (BusPolicy *policy,
- DBusConnection *receiver,
- DBusMessage *message);
-dbus_bool_t bus_policy_check_can_own (BusPolicy *policy,
- DBusConnection *connection,
- const char *service_name);
+void bus_policy_ref (BusPolicy *policy);
+void bus_policy_unref (BusPolicy *policy);
+dbus_bool_t bus_policy_check_can_send (BusPolicy *policy,
+ BusRegistry *registry,
+ DBusConnection *receiver,
+ DBusMessage *message);
+dbus_bool_t bus_policy_check_can_receive (BusPolicy *policy,
+ BusRegistry *registry,
+ DBusConnection *sender,
+ DBusMessage *message);
+dbus_bool_t bus_policy_check_can_own (BusPolicy *policy,
+ DBusConnection *connection,
+ const DBusString *service_name);