mirror of
https://github.com/Mercantec-GHC/h4-projekt-gruppe-0-sm.git
synced 2025-04-27 16:24:07 +02:00
compile with warnings
This commit is contained in:
parent
7d1eb9348c
commit
bdd141cbdf
@ -15,10 +15,10 @@ C_FLAGS = \
|
||||
-std=c17 \
|
||||
-Wall -Wextra -Wpedantic -Wconversion \
|
||||
-pedantic -pedantic-errors \
|
||||
-Wno-unused-parameter \
|
||||
-Wno-unused-parameter -Wno-format-zero-length \
|
||||
|
||||
L_FLAGS = -lm -pthread $(shell pkg-config sqlite3 openssl --libs)
|
||||
C_FLAGS = $(shell pkg-config sqlite3 openssl --cflags)
|
||||
C_FLAGS += $(shell pkg-config sqlite3 openssl --cflags)
|
||||
|
||||
F_FLAGS =
|
||||
OPTIMIZATION =
|
||||
|
@ -1,4 +1,4 @@
|
||||
xc
|
||||
-xc
|
||||
-std=c17
|
||||
-Wall
|
||||
-Wextra
|
||||
|
@ -183,7 +183,11 @@ void http_ctx_respond(HttpCtx* ctx, int status, const char* body)
|
||||
|
||||
string_push_str(&res, body);
|
||||
|
||||
write(ctx->client->file, res.data, res.size);
|
||||
ssize_t bytes_written = write(ctx->client->file, res.data, res.size);
|
||||
if (bytes_written != (ssize_t)res.size) {
|
||||
fprintf(stderr, "error: could not send response\n");
|
||||
}
|
||||
|
||||
puts("\nResponse:");
|
||||
puts(res.data);
|
||||
|
||||
|
@ -7,7 +7,7 @@
|
||||
(fputs("\x1b[1;31mpanic\x1b[97m: ", stderr), fprintf(stderr, __VA_ARGS__), \
|
||||
fprintf(stderr, "\x1b[0m\n\tin %s:%d\n\tat %s:%d\n", __func__, \
|
||||
__LINE__, __FILE__, __LINE__), \
|
||||
exit(1), 0)
|
||||
exit(1), (void)0)
|
||||
|
||||
__attribute__((unused)) static inline void ___include_user(void)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user