Commit 90b8957c authored by Per Cederqvist's avatar Per Cederqvist
Browse files

(Aux_item_validation_data): Removed item_creator, object_creator and

	owner_check.  Added creating_conn and subordinate.  Placed
	add_to_list, start_looking_at and object_type inside #if
	0..#endif, since they are not currently used.
(aux_inherit_items):Removed arguments target_creator, creating and
	object_type.  Added argument subordinate.  Changed type of
	arguments object_no and object, since we know that they are a
	Text_no and Text_stat, respectively.
(check_delete_aux_item_list): Renamed the "owner" argument
	"subordinate".
(text_stat_check_add_aux_item): Removed the item_creator and creating
	arguments.  Added the creating_conn argument.
(conf_stat_check_add_aux_item_list): Ditto.
(system_check_add_aux_item_list): Ditto.
(conf_stat_check_add_aux_item): Declaration for undefined and
	unused function removed.
(conf_stat_add_aux_item): Ditto.
parent 04eaf184
/*
* $Id: aux-items.h,v 1.24 2003/08/16 11:29:04 ceder Exp $
* $Id: aux-items.h,v 1.25 2003/08/20 08:24:37 ceder Exp $
* Copyright (C) 1994-2001 Lysator Academic Computer Association.
*
* This file is part of the LysKOM server.
......@@ -74,16 +74,21 @@ typedef struct
{
const Aux_item *item;
const Aux_item_definition *def;
Pers_no item_creator;
Pers_no object_creator;
Bool owner_check;
Connection *creating_conn;
Bool creating;
Conf_no subordinate;
#if 0
/* No validator currently use these fields, so they are
temporarily removed. See aux_item_add_perm() if you need to
re-enable any of them. */
Aux_item_list *add_to_list;
unsigned long start_looking_at;
Bool creating;
enum object_type object_type;
#endif
} Aux_item_validation_data;
typedef Bool (*Aux_item_validation_function)(Aux_item_validation_data *);
typedef Success (*Aux_item_validation_function)(Aux_item_validation_data *);
typedef struct
{
......@@ -159,11 +164,9 @@ extern Aux_item_definition empty_aux_item_definition;
void aux_inherit_items(Aux_item_list *target,
const Aux_item_list *parent,
unsigned long *counter,
Pers_no target_creator,
Bool creating,
enum object_type object_type,
unsigned long object_no,
void *object);
Conf_no subordinate,
Text_no object_no,
Text_stat *object);
......@@ -228,7 +231,7 @@ commit_aux_item_list(Aux_item_list *list_to_commit);
Success check_delete_aux_item_list(const Number_list *items_to_delete,
const Aux_item_list *list_to_delete_from,
const Conf_no owner);
const Conf_no subordinate);
......@@ -242,38 +245,34 @@ void text_stat_add_aux_item_list(Text_stat *text_s,
/* Check for permission to add items in list to aux_item_list
* of text_s. item_creator is the person adding the items. Sets
* kom_errno and err_stat and returns FAILURE if permission is
* not granted. You MUST call perpare_aux_item_list on the list
* before calling this! */
/* Check for permission to add items in ``list'' to aux_item_list of
``text_s''. ``creating_conn'' is the connection that gave the command that
attempts to add the items. Sets kom_errno and err_stat and returns
FAILURE if permission is not granted. You MUST call
perpare_aux_item_list on the list before calling this!
When this is called to check items when creating a text, pass NULL
as ``text_s''. */
Success text_stat_check_add_aux_item_list(Text_stat *text_s,
Aux_item_list *list,
Pers_no item_creator,
Bool creating);
Connection *creating_conn);
Success conf_stat_check_add_aux_item(Conference *conf,
Conf_no conf_no,
Aux_item *item,
Pers_no creator,
Aux_item_definition *def,
Bool creating);
/* Add an item to ``conf''. ``conf_no'' must correspond to ``conf''.
``list'' is the list of items to add (NULL is interpreted as an
empty list). ``creating_conn'' is the connection whose permissions
should be used. ``creating'' should be true if the conference is
being created. (The ``conf'' must be non-NULL even if the
conference is being created.) */
Success
conf_stat_check_add_aux_item_list(Conference *conf,
Conf_no conf_no,
Aux_item_list *list,
Pers_no creator,
Connection *creating_conn,
Bool creating);
void
conf_stat_add_aux_item(Conference *conf,
Conf_no conf_no,
Aux_item *item,
Aux_item_definition *def);
void
conf_stat_add_aux_item_list(Conference *conf,
Conf_no conf_no,
Aux_item_list *list,
......@@ -286,7 +285,7 @@ system_add_aux_item_list(Info *info,
Success system_check_add_aux_item_list(Info *info,
Aux_item_list *list,
Pers_no creator);
Connection *creating_conn);
void initialize_aux_items(char *);
void free_aux_item_definitions(void);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment