*: nuke ^L (page feed)
Quagga sources have inherited a slew of Page Feed (^L, \xC) characters
from ancient history. Among other things, these break patchwork's
XML-RPC API because \xC is not a valid character in XML documents.
Nuke them from high orbit.
Patches can be adapted simply by:
sed -e 's%^L%%' -i filename.patch
(you can type page feeds in some environments with Ctrl-V Ctrl-L)
Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
diff --git a/ripd/rip_debug.c b/ripd/rip_debug.c
index 662e584..a267874 100644
--- a/ripd/rip_debug.c
+++ b/ripd/rip_debug.c
@@ -27,7 +27,7 @@
unsigned long rip_debug_event = 0;
unsigned long rip_debug_packet = 0;
unsigned long rip_debug_zebra = 0;
-
+
DEFUN (show_debugging_rip,
show_debugging_rip_cmd,
"show debugging rip",
diff --git a/ripd/rip_interface.c b/ripd/rip_interface.c
index 810b71c..22cef45 100644
--- a/ripd/rip_interface.c
+++ b/ripd/rip_interface.c
@@ -41,7 +41,7 @@
#include "ripd/ripd.h"
#include "ripd/rip_debug.h"
#include "ripd/rip_interface.h"
-
+
/* static prototypes */
static void rip_enable_apply (struct interface *);
static void rip_passive_interface_apply (struct interface *);
@@ -49,7 +49,7 @@
static int rip_enable_if_lookup (const char *ifname);
static int rip_enable_network_lookup2 (struct connected *connected);
static void rip_enable_apply_all (void);
-
+
struct message ri_version_msg[] =
{
{RI_RIP_VERSION_1, "1"},
@@ -68,7 +68,7 @@
/* Vector to store passive-interface name. */
static int passive_default; /* are we in passive-interface default mode? */
vector Vrip_passive_nondefault;
-
+
/* Join to the RIP version 2 multicast group. */
static int
ipv4_multicast_join (int sock,
@@ -109,7 +109,7 @@
return ret;
}
-
+
/* Allocate new RIP's interface configuration. */
static struct rip_interface *
rip_interface_new (void)
@@ -754,7 +754,7 @@
return 0;
}
-
+
/* Check interface is enabled by network statement. */
/* Check wether the interface has at least a connected prefix that
* is within the ripng_enable_network table. */
@@ -1142,7 +1142,7 @@
vector_slot (rip_enable_interface, i) = NULL;
}
}
-
+
/* Utility function for looking up passive interface settings. */
static int
rip_passive_nondefault_lookup (const char *ifname)
@@ -1229,7 +1229,7 @@
}
rip_passive_interface_apply_all ();
}
-
+
/* RIP enable network or interface configuration. */
DEFUN (rip_network,
rip_network_cmd,
@@ -1913,7 +1913,7 @@
else
return rip_passive_nondefault_unset (vty, ifname);
}
-
+
/* Write rip configuration of each interface. */
static int
rip_interface_config_write (struct vty *vty)
diff --git a/ripd/rip_main.c b/ripd/rip_main.c
index a512fbc..e81e61b 100644
--- a/ripd/rip_main.c
+++ b/ripd/rip_main.c
@@ -126,7 +126,7 @@
exit (status);
}
-
+
/* SIGHUP handler. */
static void
sighup (void)
@@ -183,7 +183,7 @@
.handler = &sigint,
},
};
-
+
/* Main routine of ripd. */
int
main (int argc, char **argv)
diff --git a/ripd/rip_peer.c b/ripd/rip_peer.c
index fd912eb..6a3add6 100644
--- a/ripd/rip_peer.c
+++ b/ripd/rip_peer.c
@@ -32,7 +32,7 @@
/* Linked list of RIP peer. */
struct list *peer_list;
-
+
static struct rip_peer *
rip_peer_new (void)
{
diff --git a/ripd/rip_routemap.c b/ripd/rip_routemap.c
index cb87ea5..37a986c 100644
--- a/ripd/rip_routemap.c
+++ b/ripd/rip_routemap.c
@@ -32,7 +32,7 @@
#include "plist.h"
#include "ripd/ripd.h"
-
+
struct rip_metric_modifier
{
enum
@@ -160,7 +160,7 @@
}
}
}
-
+
/* `match metric METRIC' */
/* Match function return 1 if match is success else return zero. */
static route_map_result_t
@@ -323,7 +323,7 @@
route_match_ip_next_hop_compile,
route_match_ip_next_hop_free
};
-
+
/* `match ip next-hop prefix-list PREFIX_LIST' */
static route_map_result_t
@@ -370,7 +370,7 @@
route_match_ip_next_hop_prefix_list_compile,
route_match_ip_next_hop_prefix_list_free
};
-
+
/* `match ip address IP_ACCESS_LIST' */
/* Match function should return 1 if match is success else return
@@ -416,7 +416,7 @@
route_match_ip_address_compile,
route_match_ip_address_free
};
-
+
/* `match ip address prefix-list PREFIX_LIST' */
static route_map_result_t
@@ -507,7 +507,7 @@
route_match_tag_compile,
route_match_tag_free
};
-
+
/* `set metric METRIC' */
/* Set metric to attribute. */
@@ -718,7 +718,7 @@
route_set_tag_compile,
route_set_tag_free
};
-
+
#define MATCH_STR "Match values from routing table\n"
#define SET_STR "Set values in destination routing protocol\n"
diff --git a/ripd/rip_snmp.c b/ripd/rip_snmp.c
index 090ebfa..2df815b 100644
--- a/ripd/rip_snmp.c
+++ b/ripd/rip_snmp.c
@@ -33,7 +33,7 @@
#include "smux.h"
#include "ripd/ripd.h"
-
+
/* RIPv2-MIB. */
#define RIPV2MIB 1,3,6,1,2,1,23
@@ -76,7 +76,7 @@
#define TIMETICKS ASN_TIMETICKS
#define IPADDRESS ASN_IPADDRESS
#define STRING ASN_OCTET_STR
-
+
/* Define SNMP local variables. */
SNMP_LOCAL_VARIABLES
@@ -149,7 +149,7 @@
};
extern struct thread_master *master;
-
+
static u_char *
rip2Globals (struct variable *v, oid name[], size_t *length,
int exact, size_t *var_len, WriteMethod **write_method)
diff --git a/ripd/rip_zebra.c b/ripd/rip_zebra.c
index 199e85e..1f6ef61 100644
--- a/ripd/rip_zebra.c
+++ b/ripd/rip_zebra.c
@@ -33,7 +33,7 @@
/* All information about zebra. */
struct zclient *zclient = NULL;
-
+
/* RIPd to zebra command interface. */
void
rip_zebra_ipv4_add (struct prefix_ipv4 *p, struct in_addr *nexthop,
@@ -196,7 +196,7 @@
return 0;
}
-
+
/* Redistribution types */
static struct {
int type;
@@ -551,7 +551,7 @@
return CMD_WARNING;
}
-
+
/* Default information originate. */
DEFUN (rip_default_information_originate,
@@ -597,7 +597,7 @@
return CMD_SUCCESS;
}
-
+
/* RIP configuration write function. */
static int
config_write_zebra (struct vty *vty)
diff --git a/ripd/ripd.c b/ripd/ripd.c
index 01bd69e..dfeb951 100644
--- a/ripd/ripd.c
+++ b/ripd/ripd.c
@@ -61,20 +61,20 @@
/* RIP queries. */
long rip_global_queries = 0;
-
+
/* Prototypes. */
static void rip_event (enum rip_event, int);
static void rip_output_process (struct connected *, struct sockaddr_in *, int, u_char);
static int rip_triggered_update (struct thread *);
static int rip_update_jitter (unsigned long);
-
+
/* RIP output routes type. */
enum
{
rip_all_route,
rip_changed_route
};
-
+
/* RIP command strings. */
static const struct message rip_msg[] =
{
@@ -86,7 +86,7 @@
{RIP_POLL_ENTRY, "POLL ENTRY"},
{0, NULL},
};
-
+
/* Utility function to set boradcast option to the socket. */
static int
sockopt_broadcast (int sock)
@@ -2774,7 +2774,7 @@
}
return sizeof (rip_packet);
}
-
+
static int
rip_update_jitter (unsigned long time)
{
@@ -2828,7 +2828,7 @@
break;
}
}
-
+
DEFUN (router_rip,
router_rip_cmd,
"router rip",
@@ -3104,7 +3104,7 @@
"Routing information timeout timer. Default is 180.\n"
"Garbage collection timer. Default is 120.\n")
-
+
struct route_table *rip_distance_table;
struct rip_distance
@@ -3372,7 +3372,7 @@
rip_distance_unset (vty, argv[0], argv[1], argv[2]);
return CMD_SUCCESS;
}
-
+
/* Print out routes update time. */
static void
rip_vty_out_uptime (struct vty *vty, struct rip_info *rinfo)
@@ -3696,7 +3696,7 @@
"%s(config-router)# ",
1
};
-
+
/* Distribute-list update functions. */
static void
rip_distribute_update (struct distribute *dist)
@@ -3787,7 +3787,7 @@
{
rip_distribute_update_all(NULL);
}
-
+
/* Delete all added rip route. */
void
rip_clean (void)