aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHanspeter Portner <dev@open-music-kontrollers.ch>2020-07-02 21:18:49 +0200
committerHanspeter Portner <dev@open-music-kontrollers.ch>2020-07-02 21:18:49 +0200
commit5161c75c5d3af968b5f5292cef282f10993db94d (patch)
tree236f51627c8a731cc9efb104fca4ce2e6d7b3dde
parent02ea9bf9b6ebd27cdea2f728b8a2e5989ce6d1e5 (diff)
downloadsynthpod-master.tar.xz
nsmc: don't send any OSC when not under nsm.HEADmaster
-rw-r--r--VERSION2
-rw-r--r--nsmc/nsmc.h10
2 files changed, 11 insertions, 1 deletions
diff --git a/VERSION b/VERSION
index 1a1db63c..51c8f9cc 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-0.1.6251
+0.1.6253
diff --git a/nsmc/nsmc.h b/nsmc/nsmc.h
index 146b3e71..f114a36a 100644
--- a/nsmc/nsmc.h
+++ b/nsmc/nsmc.h
@@ -181,6 +181,16 @@ struct _nsmc_t {
static int
_nsmc_message_varlist(nsmc_t *nsm, const char *path, const char *fmt, va_list args)
{
+ if(!nsm)
+ {
+ return 1;
+ }
+
+ if(!nsmc_managed())
+ {
+ return 0;
+ }
+
size_t max = 0;
uint8_t *tx = varchunk_write_request_max(nsm->tx, 1024, &max);
if(!tx)