Mercurial > mplayer.hg
changeset 22941:0f247134050e
Size of response is known, no need to calculate it
author | rtogni |
---|---|
date | Mon, 09 Apr 2007 20:06:45 +0000 |
parents | 38cb73f3fe04 |
children | 8258605fb3b2 |
files | stream/realrtsp/real.c |
diffstat | 1 files changed, 3 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/stream/realrtsp/real.c Mon Apr 09 19:30:32 2007 +0000 +++ b/stream/realrtsp/real.c Mon Apr 09 20:06:45 2007 +0000 @@ -105,7 +105,7 @@ static void real_calc_response_and_checksum (char *response, char *chksum, char *challenge) { - int ch_len, resp_len; + int ch_len; int i; char *ptr; char buf[128]; @@ -145,11 +145,10 @@ calc_response_string (response, buf); /* add tail */ - resp_len = strlen (response); - strcpy (&response[resp_len], "01d0a8e3"); + strcpy (&response[32], "01d0a8e3"); /* calculate checksum */ - for (i=0; i<resp_len/4; i++) + for (i=0; i<8; i++) chksum[i] = response[i*4]; }