messenger-cli

Command-line user interface for GNUnet Messenger
Log | Files | Refs | README | LICENSE

commit 7deabe9ff611d68ae780903e4970b5d73cd13493
parent 969f1536918e342bb331acfb042bf906c307978c
Author: TheJackiMonster <thejackimonster@gmail.com>
Date:   Mon, 19 Sep 2022 09:37:30 +0200

Remove library flags from compiling and fix warning

Signed-off-by: TheJackiMonster <thejackimonster@gmail.com>

Diffstat:
MMakefile | 2+-
Msrc/chat.c | 18++++++++++--------
2 files changed, 11 insertions(+), 9 deletions(-)

diff --git a/Makefile b/Makefile @@ -71,7 +71,7 @@ release: CFLAGS += $(RELEASEFLAGS) release: $(BINARY) %.o: %.c - $(GNU_CC) $(CFLAGS) -c $< -o $@ $(LIBRARY_FLAGS) + $(GNU_CC) $(CFLAGS) -c $< -o $@ $(BINARY): $(OBJECT_FILES) $(GNU_LD) $(LDFLAGS) $^ -o $@ $(LIBRARY_FLAGS) diff --git a/src/chat.c b/src/chat.c @@ -205,11 +205,11 @@ _chat_update_layout_chats(struct MESSENGER_Application *app) if (offset_x > 0) { app->ui.left = subwin( - app->window, - rows - offset_y, - UI_ACCOUNTS_COLS_MIN, - offset_y, - 0 + app->window, + rows - offset_y, + UI_ACCOUNTS_COLS_MIN, + offset_y, + 0 ); wmove(app->window, offset_y > 0? offset_y : 0, UI_ACCOUNTS_COLS_MIN); @@ -244,12 +244,16 @@ _chat_update_layout_messages(struct MESSENGER_Application *app) UTIL_LOGO_COLS : UI_CHATS_COLS_MIN ); - int offset_x = 0; + int offset_x, cut_x; + cut_x = 0; if (cols >= cols_min_left + UI_MESSAGES_COLS_MIN) offset_x = cols_min_left + 1; else + { + offset_x = 0; goto skip_left_split; + } if (rows >= UTIL_LOGO_ROWS + UI_CHATS_ROWS_MIN) { @@ -264,8 +268,6 @@ _chat_update_layout_messages(struct MESSENGER_Application *app) else app->ui.left = subwin(app->window, rows, cols_min_left, 0, 0); - int cut_x = 0; - if (cols >= cols_min_left + UI_MESSAGES_COLS_MIN + UI_MEMBERS_COLS_MIN) { cut_x = UI_MEMBERS_COLS_MIN + 1;