shithub: riscv

Download patch

ref: bafc196c4b07261923d4f197659a26d0919cdeae
parent: 06731838403de9fa6bb4eaa6c5010b3ed70f210e
author: Sigrid Solveig Haflínudóttir <[email protected]>
date: Mon Feb 19 13:53:03 EST 2024

libtags/m4a: "gnre" is non-standard id3v1 style (non-text) - check before reading the value

--- a/sys/src/cmd/audio/libtags/m4a.c
+++ b/sys/src/cmd/audio/libtags/m4a.c
@@ -137,7 +137,7 @@
 			sz -= 4;
 			snprint((char*)d, ctx->bufsz, "%d", beuint(d));
 			txtcb(ctx, type, "", d);
-		}else if(type == Tgenre){
+		}else if(type == Tgenre && dtype != 1){
 			if(ctx->read(ctx, d, 2) != 2)
 				return -1;
 			sz -= 2;