aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/eg04-sampler.lv2
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/eg04-sampler.lv2')
-rw-r--r--plugins/eg04-sampler.lv2/sampler.c12
-rw-r--r--plugins/eg04-sampler.lv2/uris.h2
2 files changed, 7 insertions, 7 deletions
diff --git a/plugins/eg04-sampler.lv2/sampler.c b/plugins/eg04-sampler.lv2/sampler.c
index ee17312..54da799 100644
--- a/plugins/eg04-sampler.lv2/sampler.c
+++ b/plugins/eg04-sampler.lv2/sampler.c
@@ -48,10 +48,10 @@ enum {
static const char* default_sample_file = "click.wav";
typedef struct {
- SF_INFO info; // Info about sample from sndfile
- float* data; // Sample data in float
- char* path; // Path of file
- size_t path_len; // Length of path
+ SF_INFO info; // Info about sample from sndfile
+ float* data; // Sample data in float
+ char* path; // Path of file
+ uint32_t path_len; // Length of path
} Sample;
typedef struct {
@@ -111,7 +111,7 @@ typedef struct {
static Sample*
load_sample(Sampler* self, const char* path)
{
- const size_t path_len = strlen(path);
+ const size_t path_len = strlen(path);
lv2_log_trace(&self->logger, "Loading sample %s\n", path);
@@ -138,7 +138,7 @@ load_sample(Sampler* self, const char* path)
// Fill sample struct and return it
sample->data = data;
sample->path = (char*)malloc(path_len + 1);
- sample->path_len = path_len;
+ sample->path_len = (uint32_t)path_len;
memcpy(sample->path, path, path_len + 1);
return sample;
diff --git a/plugins/eg04-sampler.lv2/uris.h b/plugins/eg04-sampler.lv2/uris.h
index c981f9e..f9aa5a7 100644
--- a/plugins/eg04-sampler.lv2/uris.h
+++ b/plugins/eg04-sampler.lv2/uris.h
@@ -72,7 +72,7 @@ static inline LV2_Atom*
write_set_file(LV2_Atom_Forge* forge,
const SamplerURIs* uris,
const char* filename,
- const size_t filename_len)
+ const uint32_t filename_len)
{
LV2_Atom_Forge_Frame frame;
LV2_Atom* set = (LV2_Atom*)lv2_atom_forge_object(