summaryrefslogtreecommitdiff
path: root/nslcd/hackers.h
blob: e784ec54fa4ee45ea02d9ae3a3ad50e75df2bce5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#ifndef _HACKERS_H
#define _HACKERS_H

#include <pthread.h>
#include <pwd.h>

struct session {
	pthread_rwlock_t lock;
	size_t cnt;
	struct passwd *users;
	/* The following are only for writers */
	char *yamldir;
	int *in_user_wds;
	int in_fd;
	int in_wd_home;
	int in_wd_yaml;
};

/*struct session *hackers_session_create(void);*/ /* create */
struct session *hackers_session_create(pthread_t *);
void hackers_session_check(struct session *); /* maintain */
void hackers_session_close(struct session *); /* destroy */

void hackers_session_messup(struct session *); /* before dispatch */
void hackers_session_cleanup(struct session *); /* after dispatch */

#endif