From 496e61c506f283135a52a95dec5bf43c87e39cc8 Mon Sep 17 00:00:00 2001 From: Lars-Dominik Braun Date: Mon, 25 Aug 2008 11:36:22 +0200 Subject: piano: Fix random audioUrl decoding errors --- libpiano/src/crypt.c | 1 + 1 file changed, 1 insertion(+) (limited to 'libpiano') diff --git a/libpiano/src/crypt.c b/libpiano/src/crypt.c index 8111547..eef1057 100644 --- a/libpiano/src/crypt.c +++ b/libpiano/src/crypt.c @@ -45,6 +45,7 @@ void PianoHexToInts (const char *strHex, unsigned int **retInts, /* unsigned int = 4 bytes, 8 chars in hex */ for (i = 0; i < strHexN; i += 8) { memcpy (hexInt, strHex+i, sizeof (hexInt)-1); + hexInt[sizeof (hexInt) - 1] = 0; sscanf (hexInt, "%x", &arrInts[i/8]); } *retInts = arrInts; -- cgit v1.2.3