changeset 19258:4679f22bbdae

xor_table can't be NULL, remove useless check make xor_table static
author rtogni
date Sun, 30 Jul 2006 17:02:27 +0000
parents fb837e2ab413
children 7a9116ae7fc0
files libmpdemux/realrtsp/real.c
diffstat 1 files changed, 1 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/libmpdemux/realrtsp/real.c	Sun Jul 30 15:36:28 2006 +0000
+++ b/libmpdemux/realrtsp/real.c	Sun Jul 30 17:02:27 2006 +0000
@@ -46,7 +46,7 @@
 #define LOG
 */
 
-const unsigned char xor_table[] = {
+static const unsigned char xor_table[] = {
     0x05, 0x18, 0x74, 0xd0, 0x0d, 0x09, 0x02, 0x53,
     0xc0, 0x01, 0x05, 0x05, 0x67, 0x03, 0x19, 0x70,
     0x08, 0x27, 0x66, 0x10, 0x10, 0x72, 0x08, 0x09,
@@ -143,8 +143,6 @@
     memcpy(ptr, challenge, ch_len);
   }
   
-  if (xor_table != NULL)
-  {
     table_len = strlen(xor_table);
 
     if (table_len > 56) table_len=56;
@@ -152,7 +150,6 @@
     /* xor challenge bytewise with xor_table */
     for (i=0; i<table_len; i++)
       ptr[i] = ptr[i] ^ xor_table[i];
-  }
 
   calc_response_string (response, buf);