fixed some compiler warnings
This commit is contained in:
@ -13,6 +13,7 @@ extern unsigned int settings;
|
||||
extern unsigned int file_modifiers;
|
||||
extern unsigned int color_count;
|
||||
extern color *colors;
|
||||
unsigned long file_offset;
|
||||
|
||||
char* concat(const char *s1, const char *s2){
|
||||
const size_t len1 = strlen(s1);
|
||||
@ -150,10 +151,9 @@ void print_dir(WINDOW *win, unsigned long *line_width, unsigned long *dir_file_c
|
||||
if (*dir_file_count > 9) {
|
||||
offset_front = (snprintf(NULL, 0, "%ld", *dir_file_count)) + 1;
|
||||
}
|
||||
for (i = 0; i < *dir_file_count; i++) {
|
||||
for (i = file_offset; i < *dir_file_count; i++) {
|
||||
|
||||
unsigned long offset_back = *line_width - (snprintf(NULL,0,"%ld",dir_content[i].file_size) + 1);
|
||||
unsigned long allowed_width = *line_width+1;
|
||||
|
||||
if (dir_content[i].status & FILE_STATUS_SELECTED) {
|
||||
is_selected = 1;
|
||||
|
@ -40,6 +40,7 @@ extern char *terminal_width_empty_line;
|
||||
|
||||
int read_string(WINDOW *win, int y, int x, char *str);
|
||||
int strcmp_offset(char *in0, char *in1, char offset);
|
||||
extern void render_pass();
|
||||
|
||||
|
||||
void user_interactions() {
|
||||
@ -268,9 +269,8 @@ void open_with(){
|
||||
wresize(win_b, 5, terminal_width/3); /*the div3 just looks cool*/
|
||||
|
||||
render_pass();
|
||||
unsigned long local_width;
|
||||
unsigned long local_height;
|
||||
getmaxyx(win_b, local_height, local_width);
|
||||
local_height = getmaxy(win_b);
|
||||
|
||||
|
||||
/* TODO(2025-06-22T01:24:36) fix fixed buffer size */
|
||||
@ -308,9 +308,8 @@ void rename_hovered(){
|
||||
|
||||
render_pass();
|
||||
|
||||
unsigned long local_width;
|
||||
unsigned long local_height;
|
||||
getmaxyx(win_b, local_height, local_width);
|
||||
local_height = getmaxy(win_b);
|
||||
|
||||
/* TODO(2025-06-22T01:24:30) fix fixed buffer size */
|
||||
char *str = malloc(255);
|
||||
@ -366,9 +365,6 @@ void delete(){
|
||||
|
||||
render_pass();
|
||||
|
||||
unsigned long local_width;
|
||||
unsigned long local_height;
|
||||
getmaxyx(win_b, local_height, local_width);
|
||||
|
||||
timeout(-1); /* negative numbers block until enter is pressed */
|
||||
/* TODO(2025-06-22T01:24:30) fix fixed buffer size */
|
||||
@ -421,9 +417,8 @@ void makedir(){
|
||||
wresize(win_b, 5, terminal_width/3); /*the div3 just looks cool*/
|
||||
render_pass();
|
||||
|
||||
unsigned long local_width;
|
||||
unsigned long local_height;
|
||||
getmaxyx(win_b, local_height, local_width);
|
||||
local_height = getmaxy(win_b);
|
||||
|
||||
/* TODO(2025-07-03T01:19:55) fix fixed buffer size */
|
||||
char *str = malloc(255);
|
||||
@ -444,9 +439,8 @@ void makefile(){
|
||||
wresize(win_b, 5, terminal_width/3); /*the div3 just looks cool*/
|
||||
render_pass();
|
||||
|
||||
unsigned long local_width;
|
||||
unsigned long local_height;
|
||||
getmaxyx(win_b, local_height, local_width);
|
||||
local_height = getmaxy(win_b);
|
||||
|
||||
/* TODO(2025-07-03T01:19:49) fix fixed buffer size */
|
||||
char *str = malloc(255);
|
||||
|
Reference in New Issue
Block a user