mirror of
https://github.com/javalsai/lidm.git
synced 2025-07-03 14:25:03 +02:00
dev: use #include
s according to error's concerns
This commit is contained in:
parent
6d9b02e6de
commit
4c7d221a17
@ -3,8 +3,8 @@
|
|||||||
|
|
||||||
#include <stdbool.h>
|
#include <stdbool.h>
|
||||||
|
|
||||||
#include <config.h>
|
#include "config.h"
|
||||||
#include <sessions.h>
|
#include "sessions.h"
|
||||||
|
|
||||||
bool launch(char *user, char *passwd, struct session session, void (*cb)(void), struct behavior* behavior);
|
bool launch(char *user, char *passwd, struct session session, void (*cb)(void), struct behavior* behavior);
|
||||||
|
|
||||||
|
@ -1,13 +1,11 @@
|
|||||||
#ifndef _CONFIGH_
|
#ifndef _CONFIGH_
|
||||||
#define _CONFIGH_
|
#define _CONFIGH_
|
||||||
|
|
||||||
#include "util.h"
|
|
||||||
#include <stdbool.h>
|
#include <stdbool.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
|
||||||
#include <keys.h>
|
#include "keys.h"
|
||||||
#include <sessions.h>
|
#include "util.h"
|
||||||
#include <users.h>
|
|
||||||
|
|
||||||
// should be ansi escape codes under \x1b[...m
|
// should be ansi escape codes under \x1b[...m
|
||||||
// if not prepared accordingly, it might break
|
// if not prepared accordingly, it might break
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
|
|
||||||
#include <util.h>
|
#include "util.h"
|
||||||
|
|
||||||
enum session_type {
|
enum session_type {
|
||||||
XORG,
|
XORG,
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
#ifndef _UIH_
|
#ifndef _UIH_
|
||||||
#define _UIH_
|
#define _UIH_
|
||||||
|
|
||||||
#include <config.h>
|
#include "config.h"
|
||||||
#include <util.h>
|
#include "util.h"
|
||||||
|
|
||||||
void setup(struct config);
|
void setup(struct config);
|
||||||
int load(struct Vector * users, struct Vector * sessions);
|
int load(struct Vector * users, struct Vector * sessions);
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
|
|
||||||
#include <util.h>
|
#include "util.h"
|
||||||
|
|
||||||
struct user {
|
struct user {
|
||||||
char *shell;
|
char *shell;
|
||||||
|
@ -1,10 +1,10 @@
|
|||||||
#ifndef _UTILH_
|
#ifndef _UTILH_
|
||||||
#define _UTILH_
|
#define _UTILH_
|
||||||
|
|
||||||
#include <keys.h>
|
#include "keys.h"
|
||||||
#include <stdbool.h>
|
#include "stdbool.h"
|
||||||
#include <stdint.h>
|
#include "stdint.h"
|
||||||
#include <sys/types.h>
|
#include "sys/types.h"
|
||||||
|
|
||||||
enum keys find_keyname(char *);
|
enum keys find_keyname(char *);
|
||||||
enum keys find_ansi(char *);
|
enum keys find_ansi(char *);
|
||||||
|
12
src/auth.c
12
src/auth.c
@ -1,4 +1,3 @@
|
|||||||
#include "config.h"
|
|
||||||
#include <grp.h>
|
#include <grp.h>
|
||||||
#include <pwd.h>
|
#include <pwd.h>
|
||||||
#include <security/pam_misc.h>
|
#include <security/pam_misc.h>
|
||||||
@ -9,11 +8,12 @@
|
|||||||
#include <sys/mman.h>
|
#include <sys/mman.h>
|
||||||
#include <sys/wait.h>
|
#include <sys/wait.h>
|
||||||
|
|
||||||
#include <auth.h>
|
#include "auth.h"
|
||||||
#include <sessions.h>
|
#include "config.h"
|
||||||
#include <ui.h>
|
#include "sessions.h"
|
||||||
#include <unistd.h>
|
#include "ui.h"
|
||||||
#include <util.h>
|
#include "unistd.h"
|
||||||
|
#include "util.h"
|
||||||
|
|
||||||
int pam_conversation(int num_msg, const struct pam_message **msg,
|
int pam_conversation(int num_msg, const struct pam_message **msg,
|
||||||
struct pam_response **resp, void *appdata_ptr) {
|
struct pam_response **resp, void *appdata_ptr) {
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
|
||||||
#include <chvt.h>
|
#include "chvt.h"
|
||||||
|
|
||||||
static char *vterms[] = {"/dev/tty", "/dev/tty0", "/dev/vc/0", "/dev/systty",
|
static char *vterms[] = {"/dev/tty", "/dev/tty0", "/dev/vc/0", "/dev/systty",
|
||||||
"/dev/console"};
|
"/dev/console"};
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
#include "util.h"
|
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
|
|
||||||
#include <config.h>
|
#include "config.h"
|
||||||
|
#include "util.h"
|
||||||
|
|
||||||
bool line_parser(FILE *fd, ssize_t *blksize,
|
bool line_parser(FILE *fd, ssize_t *blksize,
|
||||||
u_char (*cb)(char *key, char *value)) {
|
u_char (*cb)(char *key, char *value)) {
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
||||||
#include <efield.h>
|
#include "efield.h"
|
||||||
#include <ui.h>
|
#include "ui.h"
|
||||||
|
|
||||||
struct editable_field field_new(char *content) {
|
struct editable_field field_new(char *content) {
|
||||||
struct editable_field __efield;
|
struct editable_field __efield;
|
||||||
|
12
src/main.c
12
src/main.c
@ -4,12 +4,12 @@
|
|||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|
||||||
#include <chvt.h>
|
#include "chvt.h"
|
||||||
#include <config.h>
|
#include "config.h"
|
||||||
#include <sessions.h>
|
#include "sessions.h"
|
||||||
#include <ui.h>
|
#include "ui.h"
|
||||||
#include <users.h>
|
#include "users.h"
|
||||||
#include <util.h>
|
#include "util.h"
|
||||||
|
|
||||||
int main(int argc, char *argv[]) {
|
int main(int argc, char *argv[]) {
|
||||||
if (argc == 2)
|
if (argc == 2)
|
||||||
|
@ -7,8 +7,8 @@
|
|||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
|
|
||||||
#include <sessions.h>
|
#include "sessions.h"
|
||||||
#include <util.h>
|
#include "util.h"
|
||||||
|
|
||||||
struct source_dir {
|
struct source_dir {
|
||||||
enum session_type type;
|
enum session_type type;
|
||||||
|
12
src/ui.c
12
src/ui.c
@ -16,12 +16,12 @@
|
|||||||
#include <time.h>
|
#include <time.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|
||||||
#include <auth.h>
|
#include "auth.h"
|
||||||
#include <efield.h>
|
#include "efield.h"
|
||||||
#include <keys.h>
|
#include "keys.h"
|
||||||
#include <sessions.h>
|
#include "sessions.h"
|
||||||
#include <ui.h>
|
#include "ui.h"
|
||||||
#include <util.h>
|
#include "util.h"
|
||||||
|
|
||||||
static void print_box();
|
static void print_box();
|
||||||
static void print_footer();
|
static void print_footer();
|
||||||
|
@ -5,8 +5,8 @@
|
|||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
|
|
||||||
#include <users.h>
|
#include "users.h"
|
||||||
#include <util.h>
|
#include "util.h"
|
||||||
|
|
||||||
static struct user __new_user(struct passwd *p) {
|
static struct user __new_user(struct passwd *p) {
|
||||||
struct user __user;
|
struct user __user;
|
||||||
|
@ -5,9 +5,9 @@
|
|||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|
||||||
#include <keys.h>
|
#include "keys.h"
|
||||||
#include <ui.h>
|
#include "ui.h"
|
||||||
#include <util.h>
|
#include "util.h"
|
||||||
|
|
||||||
static int selret_magic();
|
static int selret_magic();
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user