From fee06d68c777c71c0c38a359a1dcffc9ef30f17c Mon Sep 17 00:00:00 2001 From: Jens Arnold Date: Thu, 18 Nov 2004 20:19:40 +0000 Subject: Bug fix: First dereference, then subscript, instead of vice versa. The old code never stored the correct header, and even caused NULL pointer accesses. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@5424 a1c6a512-1295-4272-9138-f99709370657 --- apps/talk.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'apps') diff --git a/apps/talk.c b/apps/talk.c index 09d1727571..3dda67a040 100644 --- a/apps/talk.c +++ b/apps/talk.c @@ -211,9 +211,9 @@ static void mp3_callback(unsigned char** start, int* size) sent = MIN(queue[queue_read].len, 0xFFFF); *start = p_lastclip = queue[queue_read].buf; *size = sent; - curr_hd[0] = *start[1]; - curr_hd[1] = *start[2]; - curr_hd[2] = *start[3]; + curr_hd[0] = (*start)[1]; + curr_hd[1] = (*start)[2]; + curr_hd[2] = (*start)[3]; } else if (silence_add && p_silence != NULL /* want and can add silence */ && p_lastclip < p_thumbnail) /* and wasn't playing thumbnail file */ -- cgit v1.2.3