add MIT license

This commit is contained in:
2026-03-16 15:33:00 +02:00
parent 55b4ef7d5b
commit 03b9462a0c
16 changed files with 69 additions and 3 deletions
+3
View File
@@ -1,3 +1,6 @@
/* SPDX-License-Identifier: MIT */
/* Copyright (c) 2026 Oleksandr Zhylin */
#include "client.h"
#include "file_p.h"
#include "main.h"
+3
View File
@@ -1,3 +1,6 @@
/* SPDX-License-Identifier: MIT */
/* Copyright (c) 2026 Oleksandr Zhylin */
#ifndef CLIENT_H
#define CLIENT_H
+3
View File
@@ -1,3 +1,6 @@
/* SPDX-License-Identifier: MIT */
/* Copyright (c) 2026 Oleksandr Zhylin */
#include "db.h"
#include "main.h"
#include <endian.h>
+3
View File
@@ -1,3 +1,6 @@
/* SPDX-License-Identifier: MIT */
/* Copyright (c) 2026 Oleksandr Zhylin */
#ifndef DB_H
#define DB_H
#include "main.h"
+3
View File
@@ -1,3 +1,6 @@
/* SPDX-License-Identifier: MIT */
/* Copyright (c) 2026 Oleksandr Zhylin */
#include "file_p.h"
#include "db.h"
#include "main.h"
+3
View File
@@ -1,3 +1,6 @@
/* SPDX-License-Identifier: MIT */
/* Copyright (c) 2026 Oleksandr Zhylin */
#ifndef FILEP_H
#define FILEP_H
#include "main.h"
+3
View File
@@ -1,3 +1,6 @@
/* SPDX-License-Identifier: MIT */
/* Copyright (c) 2026 Oleksandr Zhylin */
#include "main.h"
#include "server.h"
#include "db.h"
+3
View File
@@ -1,3 +1,6 @@
/* SPDX-License-Identifier: MIT */
/* Copyright (c) 2026 Oleksandr Zhylin */
#ifndef MAIN_H
#define MAIN_H
#include <stddef.h>
+3
View File
@@ -1,3 +1,6 @@
/* SPDX-License-Identifier: MIT */
/* Copyright (c) 2026 Oleksandr Zhylin */
#include "main.h"
#include "session.h"
#include "user.h"
+5 -2
View File
@@ -1,8 +1,11 @@
/* SPDX-License-Identifier: MIT */
/* Copyright (c) 2026 Oleksandr Zhylin */
#ifndef SERVER_H
#define SERVER_H
#include "main.h"
int start_server();
char *get_welcome_mes();
int start_server(void);
char *get_welcome_mes(void);
void server_main_loop(server_data_t *);
void prepare_start(int argc, char *argv[]);
#endif
+3
View File
@@ -1,3 +1,6 @@
/* SPDX-License-Identifier: MIT */
/* Copyright (c) 2026 Oleksandr Zhylin */
#include "session.h"
#include "client.h"
#include "db.h"
+3
View File
@@ -1,3 +1,6 @@
/* SPDX-License-Identifier: MIT */
/* Copyright (c) 2026 Oleksandr Zhylin */
#ifndef SESSION_H
#define SESSION_H
#include "main.h"
+3
View File
@@ -1,3 +1,6 @@
/* SPDX-License-Identifier: MIT */
/* Copyright (c) 2026 Oleksandr Zhylin */
#ifndef D_TYPES_H
#define D_TYPES_H
+4 -1
View File
@@ -1,3 +1,6 @@
/* SPDX-License-Identifier: MIT */
/* Copyright (c) 2026 Oleksandr Zhylin */
#include "db.h"
#include "main.h"
#include "session.h"
@@ -8,7 +11,7 @@
int32_t create_user(session *sess, char *line) {
i_db_user_create p;
uint32_t privileges;
int32_t privileges;
int32_t res;
if (sscanf(line, "register %s %s %s", p.uname, p.pass, p.email) == 3) {
res = db_user_create(&p);
+3
View File
@@ -1,3 +1,6 @@
/* SPDX-License-Identifier: MIT */
/* Copyright (c) 2026 Oleksandr Zhylin */
#ifndef USER_H
#define USER_H