restore root test

This commit is contained in:
Mohamed Boussaffa
2016-03-07 05:42:57 +08:00
parent 8d6a3c3964
commit cb2a699d57

View File

@@ -39,7 +39,6 @@ void quit_cb (int /* i */)
{ {
if( self_pipe.second != -1 ) if( self_pipe.second != -1 )
{ {
std::cout << "writing to exit pipe\n";
write(self_pipe.second, "x", 1); write(self_pipe.second, "x", 1);
} }
else else
@@ -143,8 +142,8 @@ int main (int argc, char** argv)
return 0; return 0;
} }
//if (NEEDROOT && (geteuid() != 0)) if (NEEDROOT && (geteuid() != 0))
// forceExit(false, "You need to be root to run NetHogs!"); forceExit(false, "You need to be root to run NetHogs!");
fd_set pc_loop_fd_set; fd_set pc_loop_fd_set;
std::vector<int> pc_loop_fd_list; std::vector<int> pc_loop_fd_list;