diff options
author | Hanspeter Portner <dev@open-music-kontrollers.ch> | 2020-04-08 11:41:19 +0200 |
---|---|---|
committer | Hanspeter Portner <dev@open-music-kontrollers.ch> | 2020-04-08 11:41:19 +0200 |
commit | 96ad3c14a7668bc02bf135e107687319b60d2e74 (patch) | |
tree | 2b2708a041c20031696d2eab4a66284d22473a95 | |
parent | 6eed21f63c62944741b4f469e5f9536234a247b2 (diff) | |
download | sherlock.lv2-96ad3c14a7668bc02bf135e107687319b60d2e74.tar.xz |
fix various pedantic compiler warnings.
-rw-r--r-- | VERSION | 2 | ||||
-rw-r--r-- | atom_inspector.c | 5 | ||||
-rw-r--r-- | encoder.l | 2 | ||||
-rw-r--r-- | meson.build | 2 | ||||
-rw-r--r-- | midi_inspector.c | 5 | ||||
-rw-r--r-- | osc_inspector.c | 5 | ||||
-rw-r--r-- | sherlock_nk.c | 12 | ||||
-rw-r--r-- | sherlock_nk.h | 10 |
8 files changed, 22 insertions, 21 deletions
@@ -1 +1 @@ -0.21.25 +0.21.27 diff --git a/atom_inspector.c b/atom_inspector.c index 0ae31fe..628ec38 100644 --- a/atom_inspector.c +++ b/atom_inspector.c @@ -44,8 +44,9 @@ struct _handle_t { }; static LV2_Handle -instantiate(const LV2_Descriptor* descriptor, double rate, - const char *bundle_path, const LV2_Feature *const *features) +instantiate(const LV2_Descriptor* descriptor, double rate __attribute__((unused)), + const char *bundle_path __attribute__((unused)), + const LV2_Feature *const *features) { int i; handle_t *handle = calloc(1, sizeof(handle_t)); @@ -111,7 +111,7 @@ false return TK_BOOL; %% struct nk_token * -ttl_lex(void *data, const char *utf8, int len) +ttl_lex(void *data __attribute__((unused)), const char *utf8, int len) { yyscan_t scanner; YY_BUFFER_STATE buf; diff --git a/meson.build b/meson.build index 9ab7511..2c5f7df 100644 --- a/meson.build +++ b/meson.build @@ -1,6 +1,6 @@ project('sherlock.lv2', 'c', default_options : [ 'buildtype=release', - 'warning_level=1', + 'warning_level=3', 'werror=false', 'b_lto=false', 'c_std=gnu11']) diff --git a/midi_inspector.c b/midi_inspector.c index 79acab3..39ffe7a 100644 --- a/midi_inspector.c +++ b/midi_inspector.c @@ -46,8 +46,9 @@ struct _handle_t { }; static LV2_Handle -instantiate(const LV2_Descriptor* descriptor, double rate, - const char *bundle_path, const LV2_Feature *const *features) +instantiate(const LV2_Descriptor* descriptor, double rate __attribute__((unused)), + const char *bundle_path __attribute__((unused)), + const LV2_Feature *const *features) { int i; handle_t *handle = calloc(1, sizeof(handle_t)); diff --git a/osc_inspector.c b/osc_inspector.c index efd93bc..b392dd8 100644 --- a/osc_inspector.c +++ b/osc_inspector.c @@ -47,8 +47,9 @@ struct _handle_t { }; static LV2_Handle -instantiate(const LV2_Descriptor* descriptor, double rate, - const char *bundle_path, const LV2_Feature *const *features) +instantiate(const LV2_Descriptor* descriptor, double rate __attribute__((unused)), + const char *bundle_path __attribute__((unused)), + const LV2_Feature *const *features) { int i; handle_t *handle = calloc(1, sizeof(handle_t)); diff --git a/sherlock_nk.c b/sherlock_nk.c index a4b1ac3..8bd7e04 100644 --- a/sherlock_nk.c +++ b/sherlock_nk.c @@ -272,10 +272,10 @@ _check(struct nk_context *ctx, int32_t state) } static LV2UI_Handle -instantiate(const LV2UI_Descriptor *descriptor, const char *plugin_uri, - const char *bundle_path, LV2UI_Write_Function write_function, - LV2UI_Controller controller, LV2UI_Widget *widget, - const LV2_Feature *const *features) +instantiate(const LV2UI_Descriptor *descriptor __attribute__((unused)), + const char *plugin_uri, const char *bundle_path __attribute__((unused)), + LV2UI_Write_Function write_function, LV2UI_Controller controller, + LV2UI_Widget *widget, const LV2_Feature *const *features) { plughandle_t *handle = calloc(1, sizeof(plughandle_t)); if(!handle) @@ -455,8 +455,8 @@ _osc_bundle(plughandle_t *handle, const LV2_Atom_Object *obj) } static void -port_event(LV2UI_Handle instance, uint32_t i, uint32_t size, uint32_t urid, - const void *buf) +port_event(LV2UI_Handle instance, uint32_t i, uint32_t size __attribute__((unused)), + uint32_t urid, const void *buf) { plughandle_t *handle = instance; diff --git a/sherlock_nk.h b/sherlock_nk.h index 3f0b5dd..868d23e 100644 --- a/sherlock_nk.h +++ b/sherlock_nk.h @@ -26,16 +26,14 @@ #define MAX_LINES 2048 -typedef enum _plugin_type_t plugin_type_t; -typedef enum _item_type_t item_type_t; typedef struct _item_t item_t; typedef struct _plughandle_t plughandle_t; -enum _item_type_t { +typedef enum _item_type_t { ITEM_TYPE_NONE, ITEM_TYPE_FRAME, ITEM_TYPE_EVENT -}; +} item_type_t; struct _item_t { item_type_t type; @@ -54,11 +52,11 @@ struct _item_t { }; }; -enum _plugin_type_t { +typedef enum _plugin_type_t { SHERLOCK_ATOM_INSPECTOR, SHERLOCK_MIDI_INSPECTOR, SHERLOCK_OSC_INSPECTOR -}; +} plugin_type_t; struct _plughandle_t { LV2UI_Write_Function write_function; |