Blame modules/pam_console/configfile.h

Packit 7e982e
/* Copyright 1999, 2005 Red Hat, Inc.
Packit 7e982e
 * This software may be used under the terms of the GNU General Public
Packit 7e982e
 * License, available in the file COPYING accompanying this file.
Packit 7e982e
 */
Packit 7e982e
#ifndef _CONFIGFILE_H
Packit 7e982e
#define _CONFIGFILE_H
Packit 7e982e
#define STATIC static
Packit 7e982e
Packit 7e982e
#ifndef FALSE
Packit 7e982e
#define FALSE 0
Packit 7e982e
#endif
Packit 7e982e
#ifndef TRUE
Packit 7e982e
#define TRUE (!FALSE)
Packit 7e982e
#endif
Packit 7e982e
Packit 7e982e
/* GSList reimplementation */
Packit 7e982e
Packit 7e982e
typedef struct GSList_s GSList;
Packit 7e982e
struct GSList_s {
Packit 7e982e
	void *data;
Packit 7e982e
	GSList *next;
Packit 7e982e
};
Packit 7e982e
Packit 7e982e
typedef struct class_s class;
Packit 7e982e
struct class_s {
Packit 7e982e
	char*	name;
Packit 7e982e
	GSList*	list;
Packit 7e982e
};
Packit 7e982e
Packit 7e982e
typedef struct config_s config;
Packit 7e982e
struct config_s {
Packit 7e982e
	class*	console_class;
Packit 7e982e
	char*	mode;
Packit 7e982e
	class*	device_class;
Packit 7e982e
	char*	revert_mode;
Packit 7e982e
	char*	revert_owner;
Packit 7e982e
	char*	revert_group;
Packit 7e982e
};
Packit 7e982e
Packit 7e982e
GSList *
Packit 7e982e
g_slist_prepend(GSList *l, void *d);
Packit 7e982e
Packit 7e982e
GSList *
Packit 7e982e
g_slist_append(GSList *l, void *d);
Packit 7e982e
Packit 7e982e
void
Packit 7e982e
g_slist_free(GSList *l);
Packit 7e982e
Packit 7e982e
void
Packit 7e982e
parse_file(const char *name);
Packit 7e982e
Packit 7e982e
int
Packit 7e982e
check_console_name (const char *consolename);
Packit 7e982e
Packit 7e982e
int
Packit 7e982e
set_permissions(const char *consolename, const char *username, GSList *files);
Packit 7e982e
Packit 7e982e
int
Packit 7e982e
reset_permissions(const char *consolename, GSList *files);
Packit 7e982e
Packit 7e982e
void *
Packit 7e982e
_do_malloc(size_t req);
Packit 7e982e
Packit 7e982e
#endif /* _CONFIGFILE_H */