summaryrefslogtreecommitdiff
path: root/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'main.c')
-rw-r--r--main.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/main.c b/main.c
index 24dff4a0..129273b4 100644
--- a/main.c
+++ b/main.c
@@ -148,6 +148,9 @@ server_exec_command_line (const char *cmdline, int len, char *sendback, int sbsi
else {
strcpy (sendback, "nowplaying nothing");
}
+ if (curr) {
+ pl_item_unref (curr);
+ }
}
else {
char out[2048];
@@ -159,6 +162,9 @@ server_exec_command_line (const char *cmdline, int len, char *sendback, int sbsi
else {
strcpy (out, "nothing");
}
+ if (curr) {
+ pl_item_unref (curr);
+ }
fwrite (out, 1, strlen (out), stdout);
return 1; // exit
}