Commit def63225 authored by Christophe Massiot's avatar Christophe Massiot

* New --mtu option.

parent 4d514731
......@@ -2,7 +2,7 @@
* ipv4.c: IPv4 network abstraction layer
*****************************************************************************
* Copyright (C) 2001, 2002 VideoLAN
* $Id: ipv4.c,v 1.12 2002/05/04 15:49:56 sam Exp $
* $Id: ipv4.c,v 1.12.2.1 2002/07/19 21:12:18 massiot Exp $
*
* Authors: Christophe Massiot <massiot@via.ecp.fr>
* Mathias Kretschmer <mathias@research.att.com>
......@@ -57,10 +57,6 @@
#include "network.h"
/* Default MTU used for UDP socket. FIXME: we should issue some ioctl()
* call to get that value from the interface driver. */
#define DEFAULT_MTU 1500
/*****************************************************************************
* Local prototypes
*****************************************************************************/
......@@ -309,7 +305,7 @@ static int OpenUDP( network_socket_t * p_socket )
}
p_socket->i_handle = i_handle;
p_socket->i_mtu = DEFAULT_MTU;
p_socket->i_mtu = config_GetIntVariable( "mtu" );
return( 0 );
}
......
......@@ -2,7 +2,7 @@
* ipv6.c: IPv6 network abstraction layer
*****************************************************************************
* Copyright (C) 2002 VideoLAN
* $Id: ipv6.c,v 1.8.2.1 2002/06/09 22:33:53 massiot Exp $
* $Id: ipv6.c,v 1.8.2.2 2002/07/19 21:12:18 massiot Exp $
*
* Authors: Alexis Guillard <alexis.guillard@bt.com>
* Christophe Massiot <massiot@via.ecp.fr>
......@@ -55,10 +55,6 @@
#include "network.h"
/* Default MTU used for UDP socket. FIXME: we should issue some ioctl()
* call to get that value from the interface driver. */
#define DEFAULT_MTU 1500
#if defined(WIN32)
static const struct in6_addr in6addr_any = {{IN6ADDR_ANY_INIT}};
#endif
......@@ -363,7 +359,7 @@ static int OpenUDP( network_socket_t * p_socket )
}
p_socket->i_handle = i_handle;
p_socket->i_mtu = DEFAULT_MTU;
p_socket->i_mtu = config_GetIntVariable( "mtu" );
return( 0 );
}
......
......@@ -4,7 +4,7 @@
* and spawn threads.
*****************************************************************************
* Copyright (C) 1998-2001 VideoLAN
* $Id: main.c,v 1.195.2.2 2002/06/03 17:19:54 sam Exp $
* $Id: main.c,v 1.195.2.3 2002/07/19 21:12:18 massiot Exp $
*
* Authors: Vincent Seguin <seguin@via.ecp.fr>
* Samuel Hocevar <sam@zoy.org>
......@@ -217,6 +217,11 @@
#define SERVER_PORT_LONGTEXT N_( \
"This is the port used for UDP streams. By default, we chose 1234.")
#define MTU_TEXT N_("MTU of the interface")
#define MTU_LONGTEXT N_( \
"This is the typical size of UDP packets that we expect. On Ethernet " \
"it is usually 1500.")
#define NETCHANNEL_TEXT N_("enable network channel mode")
#define NETCHANNEL_LONGTEXT N_( \
"Activate this option if you want to use the VideoLAN Channel Server.")
......@@ -391,6 +396,8 @@ ADD_INTEGER ( "server-port", 1234, NULL, SERVER_PORT_TEXT, SERVER_PORT_LONGTEXT
ADD_BOOL ( "network-channel", 0, NULL, NETCHANNEL_TEXT, NETCHANNEL_LONGTEXT )
ADD_STRING ( "channel-server", "localhost", NULL, CHAN_SERV_TEXT, CHAN_SERV_LONGTEXT )
ADD_INTEGER ( "channel-port", 6010, NULL, CHAN_PORT_TEXT, CHAN_PORT_LONGTEXT )
ADD_INTEGER ( "server-port", 1234, NULL, SERVER_PORT_TEXT, SERVER_PORT_LONGTEXT )
ADD_INTEGER ( "mtu", 1500, NULL, MTU_TEXT, MTU_LONGTEXT )
ADD_STRING ( "iface", "eth0", NULL, IFACE_TEXT, IFACE_LONGTEXT )
ADD_INTEGER ( "program", 0, NULL, INPUT_PROGRAM_TEXT, INPUT_PROGRAM_LONGTEXT )
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment