[packages] olsrd: trivial, fixing copyright header
[feed/routing.git] / patches / 100-no_forwarding_override.patch
1 --- a/src/linux/net.c
2 +++ b/src/linux/net.c
3 @@ -174,11 +174,13 @@ static bool is_at_least_linuxkernel_2_6_
4 */
5 void
6 net_os_set_global_ifoptions(void) {
7 +#if 0
8 if (writeToProc(olsr_cnf->ip_version == AF_INET ? PROC_IPFORWARD_V4 : PROC_IPFORWARD_V6, &orig_fwd_state, '1')) {
9 OLSR_PRINTF(1, "Warning, could not enable IP forwarding!\n"
10 "you should manually ensure that IP forwarding is enabled!\n\n");
11 olsr_startup_sleep(3);
12 }
13 +#endif
14
15 if (olsr_cnf->smart_gw_active) {
16 char procfile[FILENAME_MAX];
17 @@ -273,10 +275,12 @@ net_os_restore_ifoptions(void)
18
19 OLSR_PRINTF(1, "Restoring network state\n");
20
21 +#if 0
22 /* Restore IP forwarding to "off" */
23 if (writeToProc(olsr_cnf->ip_version == AF_INET ? PROC_IPFORWARD_V4 : PROC_IPFORWARD_V6, NULL, orig_fwd_state)) {
24 OLSR_PRINTF(1, "Error, could not restore ip_forward settings\n");
25 }
26 +#endif
27
28 if (olsr_cnf->smart_gw_active && (olsr_cnf->ip_version == AF_INET || olsr_cnf->use_niit)) {
29 /* Generate the procfile name */