mirror of
https://github.com/sle118/squeezelite-esp32.git
synced 2025-12-07 12:07:09 +03:00
memory leak in AirPlay
This commit is contained in:
@@ -109,6 +109,7 @@ bool led_unconfig(int idx) {
|
||||
if (idx >= MAX_LED) return false;
|
||||
|
||||
if (leds[idx].timer) xTimerDelete(leds[idx].timer, BLOCKTIME);
|
||||
leds[idx].timer = NULL;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -168,7 +168,6 @@ struct raop_ctx_s *raop_create(struct in_addr host, char *name,
|
||||
}
|
||||
|
||||
#ifdef WIN32
|
||||
|
||||
getsockname(ctx->sock, (struct sockaddr *) &addr, &nlen);
|
||||
ctx->port = ntohs(addr.sin_port);
|
||||
#endif
|
||||
|
||||
@@ -80,7 +80,7 @@
|
||||
#define RTP_SYNC (0x01)
|
||||
#define NTP_SYNC (0x02)
|
||||
|
||||
#define RESEND_TO 200
|
||||
#define RESEND_TO 200
|
||||
|
||||
enum { DATA = 0, CONTROL, TIMING };
|
||||
|
||||
@@ -291,13 +291,14 @@ void rtp_end(rtp_t *ctx)
|
||||
#else
|
||||
ctx->joiner = xTaskGetCurrentTaskHandle();
|
||||
xTaskNotifyWait(0, 0, NULL, portMAX_DELAY);
|
||||
#endif
|
||||
}
|
||||
#endif
|
||||
}
|
||||
for (i = 0; i < 3; i++) closesocket(ctx->rtp_sockets[i].sock);
|
||||
|
||||
|
||||
delete_alac(ctx->alac_codec);
|
||||
if (ctx->decrypt_buf) free(ctx->decrypt_buf);
|
||||
|
||||
pthread_mutex_destroy(&ctx->ab_mutex);
|
||||
buffer_release(ctx->audio_buffer);
|
||||
|
||||
free(ctx);
|
||||
|
||||
Reference in New Issue
Block a user