frontend: fix all compiler warnings
This commit is contained in:
@@ -33,7 +33,7 @@ void load_buf_from_history(struct line_ed *ed)
|
||||
{
|
||||
b_string *cur = (b_string *)b_array_at(ed->l_history, ed->l_history_pos);
|
||||
size_t len
|
||||
= MIN(ed->l_buf_end - ed->l_buf - 1,
|
||||
= MIN((size_t)(ed->l_buf_end - ed->l_buf - 1),
|
||||
b_string_get_size(cur, B_STRLEN_NORMAL));
|
||||
|
||||
memcpy(ed->l_buf, b_string_ptr(cur), len);
|
||||
@@ -57,7 +57,7 @@ void load_buf_from_history(struct line_ed *ed)
|
||||
|
||||
const char *last_history_line(struct line_ed *ed)
|
||||
{
|
||||
unsigned long nlines = b_array_size(ed->l_history);
|
||||
size_t nlines = b_array_size(ed->l_history);
|
||||
if (nlines < 2) {
|
||||
return NULL;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user