More removal of "#if 0" content.
This commit is contained in:
parent
edd9ca5743
commit
d35ef0f666
@ -52,18 +52,6 @@ static int req_recv;
|
|||||||
|
|
||||||
#define MS_TDIFF(tv1,tv2) ( ((tv1).tv_sec-(tv2).tv_sec)*1000 + \
|
#define MS_TDIFF(tv1,tv2) ( ((tv1).tv_sec-(tv2).tv_sec)*1000 + \
|
||||||
((tv1).tv_usec-(tv2).tv_usec)/1000 )
|
((tv1).tv_usec-(tv2).tv_usec)/1000 )
|
||||||
#if 0
|
|
||||||
static void set_signal(int signo, void (*handler) (void))
|
|
||||||
{
|
|
||||||
struct sigaction sa;
|
|
||||||
|
|
||||||
memset(&sa, 0, sizeof(sa));
|
|
||||||
sa.sa_handler = (void (*)(int)) handler;
|
|
||||||
sa.sa_flags = SA_RESTART;
|
|
||||||
sigaction(signo, &sa, NULL);
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
static int send_pack(int sock, struct in_addr *src_addr,
|
static int send_pack(int sock, struct in_addr *src_addr,
|
||||||
struct in_addr *dst_addr, struct sockaddr_ll *ME,
|
struct in_addr *dst_addr, struct sockaddr_ll *ME,
|
||||||
struct sockaddr_ll *HE)
|
struct sockaddr_ll *HE)
|
||||||
|
@ -43,11 +43,7 @@
|
|||||||
#define MAX_INTERFACE_LENGTH 10
|
#define MAX_INTERFACE_LENGTH 10
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if 0
|
|
||||||
#define debug_noise(fmt, args...) printf(fmt, ## args)
|
|
||||||
#else
|
|
||||||
#define debug_noise(fmt, args...)
|
#define debug_noise(fmt, args...)
|
||||||
#endif
|
|
||||||
|
|
||||||
/* Forward declaration */
|
/* Forward declaration */
|
||||||
struct interface_defn_t;
|
struct interface_defn_t;
|
||||||
|
@ -25,58 +25,6 @@
|
|||||||
|
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
#if 0
|
|
||||||
int preferred_family = AF_UNSPEC;
|
|
||||||
int oneline = 0;
|
|
||||||
char * _SL_ = NULL;
|
|
||||||
|
|
||||||
void ip_parse_common_args(int *argcp, char ***argvp)
|
|
||||||
{
|
|
||||||
int argc = *argcp;
|
|
||||||
char **argv = *argvp;
|
|
||||||
|
|
||||||
while (argc > 1) {
|
|
||||||
char *opt = argv[1];
|
|
||||||
|
|
||||||
if (strcmp(opt,"--") == 0) {
|
|
||||||
argc--; argv++;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (opt[0] != '-')
|
|
||||||
break;
|
|
||||||
|
|
||||||
if (opt[1] == '-')
|
|
||||||
opt++;
|
|
||||||
|
|
||||||
if (matches(opt, "-family") == 0) {
|
|
||||||
argc--;
|
|
||||||
argv++;
|
|
||||||
if (strcmp(argv[1], "inet") == 0)
|
|
||||||
preferred_family = AF_INET;
|
|
||||||
else if (strcmp(argv[1], "inet6") == 0)
|
|
||||||
preferred_family = AF_INET6;
|
|
||||||
else if (strcmp(argv[1], "link") == 0)
|
|
||||||
preferred_family = AF_PACKET;
|
|
||||||
else
|
|
||||||
invarg(bb_msg_invalid_arg, argv[1], "-family");
|
|
||||||
} else if (strcmp(opt, "-4") == 0) {
|
|
||||||
preferred_family = AF_INET;
|
|
||||||
} else if (strcmp(opt, "-6") == 0) {
|
|
||||||
preferred_family = AF_INET6;
|
|
||||||
} else if (strcmp(opt, "-0") == 0) {
|
|
||||||
preferred_family = AF_PACKET;
|
|
||||||
} else if (matches(opt, "-oneline") == 0) {
|
|
||||||
++oneline;
|
|
||||||
} else {
|
|
||||||
bb_show_usage();
|
|
||||||
}
|
|
||||||
argc--; argv++;
|
|
||||||
}
|
|
||||||
_SL_ = oneline ? "\\" : "\n" ;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
int ip_main(int argc, char **argv)
|
int ip_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
int ret = EXIT_FAILURE;
|
int ret = EXIT_FAILURE;
|
||||||
|
@ -351,12 +351,6 @@ static void ping(const char *host)
|
|||||||
struct icmp6_filter filt;
|
struct icmp6_filter filt;
|
||||||
if (!(options & O_VERBOSE)) {
|
if (!(options & O_VERBOSE)) {
|
||||||
ICMP6_FILTER_SETBLOCKALL(&filt);
|
ICMP6_FILTER_SETBLOCKALL(&filt);
|
||||||
#if 0
|
|
||||||
if ((options & F_FQDN) || (options & F_FQDNOLD) ||
|
|
||||||
(options & F_NODEADDR) || (options & F_SUPTYPES))
|
|
||||||
ICMP6_FILTER_SETPASS(ICMP6_NI_REPLY, &filt);
|
|
||||||
else
|
|
||||||
#endif
|
|
||||||
ICMP6_FILTER_SETPASS(ICMP6_ECHO_REPLY, &filt);
|
ICMP6_FILTER_SETPASS(ICMP6_ECHO_REPLY, &filt);
|
||||||
} else {
|
} else {
|
||||||
ICMP6_FILTER_SETPASSALL(&filt);
|
ICMP6_FILTER_SETPASSALL(&filt);
|
||||||
|
@ -628,11 +628,7 @@ static void INET6_displayroutes(int noresolve)
|
|||||||
snaddr6.sin6_family = AF_INET6;
|
snaddr6.sin6_family = AF_INET6;
|
||||||
INET6_rresolve(naddr6, sizeof(naddr6),
|
INET6_rresolve(naddr6, sizeof(naddr6),
|
||||||
(struct sockaddr_in6 *) &snaddr6,
|
(struct sockaddr_in6 *) &snaddr6,
|
||||||
#if 0
|
|
||||||
(noresolve | 0x8000) /* Default instead of *. */
|
|
||||||
#else
|
|
||||||
0x0fff /* Apparently, upstream never resolves. */
|
0x0fff /* Apparently, upstream never resolves. */
|
||||||
#endif
|
|
||||||
);
|
);
|
||||||
|
|
||||||
if (!r) { /* 1st pass */
|
if (!r) { /* 1st pass */
|
||||||
|
@ -34,10 +34,6 @@
|
|||||||
#include <netinet/in.h>
|
#include <netinet/in.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
#if 0
|
|
||||||
enum { DOTRACE = 1 };
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef DOTRACE
|
#ifdef DOTRACE
|
||||||
#include <arpa/inet.h> /* for inet_ntoa()... */
|
#include <arpa/inet.h> /* for inet_ntoa()... */
|
||||||
#define TRACE(x, y) do { if (x) printf y; } while (0)
|
#define TRACE(x, y) do { if (x) printf y; } while (0)
|
||||||
@ -311,17 +307,6 @@ static void putiac2(byte wwdd, byte c)
|
|||||||
putiac(c);
|
putiac(c);
|
||||||
}
|
}
|
||||||
|
|
||||||
#if 0
|
|
||||||
static void putiac1(byte c)
|
|
||||||
{
|
|
||||||
if (G.iaclen + 2 > IACBUFSIZE)
|
|
||||||
iacflush();
|
|
||||||
|
|
||||||
putiac(IAC);
|
|
||||||
putiac(c);
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CONFIG_FEATURE_TELNET_TTYPE
|
#ifdef CONFIG_FEATURE_TELNET_TTYPE
|
||||||
static void putiac_subopt(byte c, char *str)
|
static void putiac_subopt(byte c, char *str)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user