mirror of
https://github.com/ChronosX88/netsukuku.git
synced 2024-11-26 04:02:19 +00:00
I, FINALLY, Fixed the bug where netsukuku just crashed in restricted mode, Without restoring /etc/resolv.conf. However! I did this by bypassing fatal(). This is kind of a hack, Netsukuku will probably be able to restore /etc/resolv.conf without this, Once the tunl0 bug is fixed, Thus preventing fatal from being called.
This commit is contained in:
parent
c61afcb0db
commit
b7f8a6cdb9
@ -307,13 +307,15 @@ void init_internet_gateway_search(void)
|
|||||||
* Bring tunl0 up (just to test if the ipip module is loaded)
|
* Bring tunl0 up (just to test if the ipip module is loaded)
|
||||||
*/
|
*/
|
||||||
loginfo("Configuring the \"" DEFAULT_TUNL_IF "\" tunnel device");
|
loginfo("Configuring the \"" DEFAULT_TUNL_IF "\" tunnel device");
|
||||||
if(tunnel_change(0, 0, 0, DEFAULT_TUNL_PREFIX, DEFAULT_TUNL_NUMBER) < 0)
|
if(tunnel_change(0, 0, 0, DEFAULT_TUNL_PREFIX, DEFAULT_TUNL_NUMBER) < 0) {
|
||||||
fatal("Cannot initialize \"" DEFAULT_TUNL_IF "\". "
|
printf("Cannot initialize \"" DEFAULT_TUNL_IF "\". "
|
||||||
"Is the \"ipip\" kernel module loaded?\n"
|
"Is the \"ipip\" kernel module loaded?\n"
|
||||||
" If you don't care about using the shared internet "
|
" If you don't care about using the shared internet "
|
||||||
"connections of the ntk nodes\n"
|
"connections of the ntk nodes\n"
|
||||||
" around you, disable the \"use_shared_inet\" option "
|
" around you, disable the \"use_shared_inet\" option "
|
||||||
"in netsukuku.conf");
|
"in netsukuku.conf");
|
||||||
|
del_resolv_conf("nameserver 127.0.0.1", "/etc/resolv.conf");
|
||||||
|
exit(1);}
|
||||||
ifs_del_all_name(me.cur_ifs, &me.cur_ifs_n, NTK_TUNL_PREFIX);
|
ifs_del_all_name(me.cur_ifs, &me.cur_ifs_n, NTK_TUNL_PREFIX);
|
||||||
ifs_del_all_name(me.cur_ifs, &me.cur_ifs_n, DEFAULT_TUNL_PREFIX);
|
ifs_del_all_name(me.cur_ifs, &me.cur_ifs_n, DEFAULT_TUNL_PREFIX);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user