diff options
| author | Riley Beckett <rbeckettvt@gmail.com> | 2026-04-11 22:28:39 -0400 |
|---|---|---|
| committer | Riley Beckett <rbeckettvt@gmail.com> | 2026-04-11 22:28:39 -0400 |
| commit | bbfbacc75e9bcb8a8b9d81b5f2a06567734c2873 (patch) | |
| tree | 0553947878040daee598d17a5aca600fa8134c4b | |
| parent | 820afc0d5af5d1536ecb7faaac86d01e788dacdf (diff) | |
fix some compiler error
| -rw-r--r-- | Makefile | 2 | ||||
| -rw-r--r-- | args.c | 2 | ||||
| -rw-r--r-- | input_field.c | 5 | ||||
| -rw-r--r-- | main.c | 2 | ||||
| -rw-r--r-- | state.h | 2 |
5 files changed, 6 insertions, 7 deletions
@@ -54,7 +54,7 @@ compile_flags: echo $(CFLAGS) | tr ' ' '\n' > compile_flags.txt clean: - rm -rf $(BIN) $(OBJDIR) + rm -rf $(BIN) $(OBJDIR) swenu-exes install: all install -m 755 ./$(BIN) $(PREFIX)/bin @@ -46,7 +46,7 @@ void parse_args(client_state* state, int argc, char* argv[]) { state->orderless = true; break; case 'i': - state->strstr = strcasestr; + state->strstr2 = strcasestr; break; case 's': array_insert_many(state->input_buffer, 0, optarg, strlen(optarg)); diff --git a/input_field.c b/input_field.c index c221e6f..d8c5c23 100644 --- a/input_field.c +++ b/input_field.c @@ -35,7 +35,7 @@ void refilter_items(client_state* state) { float part = 0; bool add = true; array_for_all(char*, j, parts) { - if (state->strstr(i->text, *j)) { + if (state->strstr2(i->text, *j)) { part += strlen(*j); } else { @@ -57,7 +57,7 @@ void refilter_items(client_state* state) { } else { array_for_all(item_t, i, state->items) { - if (state->strstr(i->text, input_buffer_string) != NULL) { + if (state->strstr2(i->text, input_buffer_string) != NULL) { array_add(state->filtered_items, (item_display_t){ .item = i }); } } @@ -166,4 +166,3 @@ key_repeat_t execute_keypress(client_state* state, xkb_keysym_t keysym) { return KEY_NO_REPEAT; } - @@ -45,7 +45,7 @@ int main(int argc, char* argv[]) { state.input_buffer = array_new(char, 0); state.filtered_items = array_new(item_display_t, 0); state.page_indices = array_new(size_t, 0); - state.strstr = strstr; + state.strstr2 = strstr; // check locale setlocale(LC_ALL, ""); @@ -121,7 +121,7 @@ typedef struct { bool verbose; bool password; bool orderless; - char* (*strstr)(const char*, const char*); + char* (*strstr2)(const char*, const char*); // input item_t* items; |
