Commit 94bdf708 authored by Christophe Massiot's avatar Christophe Massiot

* New --mtu option.

parent b2da0544
......@@ -2,7 +2,7 @@
* ipv4.c: IPv4 network abstraction layer
*****************************************************************************
* Copyright (C) 2001, 2002 VideoLAN
* $Id: ipv4.c,v 1.13 2002/06/01 12:32:00 sam Exp $
* $Id: ipv4.c,v 1.14 2002/07/19 21:14:13 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
*****************************************************************************/
......@@ -305,7 +301,7 @@ static int OpenUDP( vlc_object_t * p_this, network_socket_t * p_socket )
}
p_socket->i_handle = i_handle;
p_socket->i_mtu = DEFAULT_MTU;
p_socket->i_mtu = config_GetInt( p_this, "mtu" );
return( 0 );
}
......
......@@ -2,7 +2,7 @@
* ipv6.c: IPv6 network abstraction layer
*****************************************************************************
* Copyright (C) 2002 VideoLAN
* $Id: ipv6.c,v 1.12 2002/06/09 23:35:33 massiot Exp $
* $Id: ipv6.c,v 1.13 2002/07/19 21:14:13 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
......@@ -359,7 +355,8 @@ static int OpenUDP( vlc_object_t * p_this, network_socket_t * p_socket )
}
p_socket->i_handle = i_handle;
p_socket->i_mtu = DEFAULT_MTU;
p_socket->i_mtu = config_GetInt( p_this, "mtu" );
return( 0 );
}
......
......@@ -2,7 +2,7 @@
* libvlc.h: main libvlc header
*****************************************************************************
* Copyright (C) 1998-2002 VideoLAN
* $Id: libvlc.h,v 1.5 2002/06/27 19:05:17 sam Exp $
* $Id: libvlc.h,v 1.6 2002/07/19 21:14:13 massiot Exp $
*
* Authors: Vincent Seguin <seguin@via.ecp.fr>
* Samuel Hocevar <sam@zoy.org>
......@@ -162,6 +162,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.")
......@@ -354,6 +359,7 @@ 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 ( "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