~hp/eteroj.lv2

679f9932085a4540cde28c993cbe946285163872 — Hanspeter Portner 1 year, 2 days ago cc21ed7
Fix compiler warnings
6 files changed, 28 insertions(+), 30 deletions(-)

M eteroj.lv2/eteroj.h
M meson_options.txt
M src/eteroj_cloak.c
M src/eteroj_io.c
M src/eteroj_ninja.c
M src/eteroj_pack.c
M eteroj.lv2/eteroj.h => eteroj.lv2/eteroj.h +3 -6
@@ 18,13 18,10 @@
#ifndef _ETEROJ_LV2_H
#define _ETEROJ_LV2_H

#define UNUSED __attribute__((unused))

#include <stdint.h>
#if !defined(_WIN32)
#	include <sys/mman.h>
#else
#	define mlock(...)
#	define munlock(...)
#endif
#include <sys/mman.h>

#include "lv2/lv2plug.in/ns/ext/atom/atom.h"
#include "lv2/lv2plug.in/ns/ext/atom/forge.h"

M meson_options.txt => meson_options.txt +1 -1
@@ 9,4 9,4 @@ option('lv2libdir',
	type : 'string',
	value : 'lib/lv2')

option('version', type : 'string', value : '0.11.27')
option('version', type : 'string', value : '0.11.33')

M src/eteroj_cloak.c => src/eteroj_cloak.c +3 -3
@@ 43,8 43,8 @@ struct _plughandle_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 UNUSED,
	const char *bundle_path UNUSED, const LV2_Feature *const *features)
{
	plughandle_t *handle = calloc(1, sizeof(plughandle_t));
	if(!handle)


@@ 163,7 163,7 @@ _7bit_encode(uint8_t *dst, const uint8_t *src, uint32_t size)
}

static void
run(LV2_Handle instance, uint32_t nsamples)
run(LV2_Handle instance, uint32_t nsamples UNUSED)
{
	plughandle_t *handle = (plughandle_t *)instance;


M src/eteroj_io.c => src/eteroj_io.c +6 -6
@@ 174,7 174,7 @@ _url_change(plughandle_t *handle, const char *url)
}

static void
_intercept(void *data, int64_t frames, props_impl_t *impl)
_intercept(void *data, int64_t frames UNUSED, props_impl_t *impl)
{
	plughandle_t *handle = data;



@@ 205,8 205,8 @@ static const props_def_t defs [MAX_NPROPS] = {
};

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 UNUSED,
	const char *bundle_path UNUSED, const LV2_Feature *const *features)
{
	plughandle_t *handle = calloc(1, sizeof(plughandle_t));
	if(!handle)


@@ 672,8 672,8 @@ static LV2_Worker_Status
_work(LV2_Handle instance,
	LV2_Worker_Respond_Function respond,
	LV2_Worker_Respond_Handle target,
	uint32_t _size,
	const void *_body)
	uint32_t _size UNUSED,
	const void *_body UNUSED)
{
	plughandle_t *handle = instance;
	char *osc_url = NULL;


@@ 740,7 740,7 @@ _work_response(LV2_Handle instance, uint32_t size, const void *body)

// rt-thread
static LV2_Worker_Status
_end_run(LV2_Handle instance)
_end_run(LV2_Handle instance UNUSED)
{
	// do nothing


M src/eteroj_ninja.c => src/eteroj_ninja.c +6 -5
@@ 125,8 125,8 @@ static const props_def_t defs [MAX_NPROPS] = {
};

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 UNUSED,
	const char *bundle_path UNUSED, const LV2_Feature *const *features)
{
	plughandle_t *handle = calloc(1, sizeof(plughandle_t));
	if(!handle)


@@ 293,7 293,7 @@ _convert_seq(plughandle_t *handle, LV2_Atom_Forge *forge, const LV2_Atom_Sequenc
}

static void
run(LV2_Handle instance, uint32_t nsamples)
run(LV2_Handle instance, uint32_t nsamples UNUSED)
{
	plughandle_t *handle = (plughandle_t *)instance;



@@ 438,7 438,8 @@ _work(LV2_Handle instance,

// rt-thread
static LV2_Worker_Status
_work_response(LV2_Handle instance, uint32_t size, const void *body)
_work_response(LV2_Handle instance UNUSED,
	uint32_t size UNUSED, const void *body UNUSED)
{
	// do nothing



@@ 447,7 448,7 @@ _work_response(LV2_Handle instance, uint32_t size, const void *body)

// rt-thread
static LV2_Worker_Status
_end_run(LV2_Handle instance)
_end_run(LV2_Handle instance UNUSED)
{
	// do nothing


M src/eteroj_pack.c => src/eteroj_pack.c +9 -9
@@ 26,14 26,13 @@
#define MAX_NPROPS 2
#define MAX_STRLEN 512

typedef enum _pack_format_t pack_format_t;
typedef struct _plugstate_t plugstate_t;
typedef struct _plughandle_t plughandle_t;

enum _pack_format_t {
typedef enum _pack_format_t {
	PACK_FORMAT_MIDI = 0,
	PACK_FORMAT_BLOB = 1
};
} pack_format_t;

typedef struct _plugstate_t plugstate_t;
typedef struct _plughandle_t plughandle_t;

struct _plugstate_t {
	char pack_path [MAX_STRLEN];


@@ 75,7 74,8 @@ static const props_def_t defs [MAX_NPROPS] = {
};

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 UNUSED,
	const char *bundle_path UNUSED, const LV2_Feature *const *features)
{
	plughandle_t *handle = calloc(1, sizeof(plughandle_t));
	if(!handle)


@@ 129,7 129,7 @@ connect_port(LV2_Handle instance, uint32_t port, void *data)
}

static void
_unroll(const char *path, const LV2_Atom_Tuple *arguments, void *data)
_unroll(const char *path UNUSED, const LV2_Atom_Tuple *arguments, void *data)
{
	plughandle_t *handle = data;
	LV2_Atom_Forge *forge = &handle->forge;


@@ 168,7 168,7 @@ _unroll(const char *path, const LV2_Atom_Tuple *arguments, void *data)
}

static void
run(LV2_Handle instance, uint32_t nsamples)
run(LV2_Handle instance, uint32_t nsamples UNUSED)
{
	plughandle_t *handle = (plughandle_t *)instance;