Giter VIP home page Giter VIP logo

nettop's People

Contributors

emanem avatar figbux avatar thomas-mc-work avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

nettop's Issues

Add a pause option

Can you add a pause option?
It's desireable to analize each ip per application, an avoid it disappear with every screen refresh.
Thanks

nettop exits when window is resized on i3

Hi, with the latest commit b79390c , on i3wm, the nettop program exits when its windows is resized. This started happening when I pulled and ran with the aforementioned commit

Error shown is:

Exception: Error in epoll_wait: Interrupted system call

hit q to exit

It would be nice to be able to exit the tool by hitting the q button (which is quite common in such linux tools).

Compilation error (gcc 11.0.0)

Hello,
Thanks for the great work, however I couldn't get it compiled using gcc 11.1.0. Error log is below:

$ make release
mkdir -p obj
touch obj/__setup_obj_dir
g++ -g -Wall -std=c++11 -pthread  -O3 -D_RELEASE src/settings.cpp -c -o obj/settings.o
g++ -g -Wall -std=c++11 -pthread  -O3 -D_RELEASE src/main.cpp -c -o obj/main.o
g++ -g -Wall -std=c++11 -pthread  -O3 -D_RELEASE src/packet_stats.cpp -c -o obj/packet_stats.o
g++ -g -Wall -std=c++11 -pthread  -O3 -D_RELEASE src/async_log.cpp -c -o obj/async_log.o
g++ -g -Wall -std=c++11 -pthread  -O3 -D_RELEASE src/proc.cpp -c -o obj/proc.o
src/proc.cpp: In constructor ‘nettop::proc_mgr::proc_mgr()’:
src/proc.cpp:79:65: warning: ‘%s’ directive output may be truncated writing up to 255 bytes into a region of size between 107 and 117 [-Wformat-truncation=]
   79 |                         std::snprintf(cur_sd, 128, "/proc/%i/fd/%s", pid, entry->d_name);
      |                                                                 ^~
src/proc.cpp:79:38: note: ‘snprintf’ output between 12 and 277 bytes into a destination of size 128
   79 |                         std::snprintf(cur_sd, 128, "/proc/%i/fd/%s", pid, entry->d_name);
      |                         ~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
g++ -g -Wall -std=c++11 -pthread  -O3 -D_RELEASE src/name_res.cpp -c -o obj/name_res.o
In file included from src/name_res.cpp:20:
src/name_res.h:39:22: error: ‘shared_ptr’ in namespace ‘std’ does not name a template type
   39 |                 std::shared_ptr<std::thread>    thrd_;
      |                      ^~~~~~~~~~
src/name_res.h:29:1: note: ‘std::shared_ptr’ is defined in header ‘<memory>; did you forget to ‘#include <memory>’?
   28 | #include <map>
  +++ |+#include <memory>
   29 | 
src/name_res.cpp: In constructor ‘nettop::name_res::name_res(volatile bool&, bool)’:
src/name_res.cpp:39:9: error: ‘thrd_’ was not declared in this scope
   39 |         thrd_ = std::shared_ptr<std::thread>(do_not_resolve ? 0 : new std::thread(&name_res::thread_proc, this));
      |         ^~~~~
src/name_res.cpp:39:22: error: ‘shared_ptr’ is not a member of ‘std’
   39 |         thrd_ = std::shared_ptr<std::thread>(do_not_resolve ? 0 : new std::thread(&name_res::thread_proc, this));
      |                      ^~~~~~~~~~
src/name_res.cpp:21:1: note: ‘std::shared_ptr’ is defined in header ‘<memory>; did you forget to ‘#include <memory>’?
   20 | #include "name_res.h"
  +++ |+#include <memory>
   21 | 
src/name_res.cpp:39:44: error: expected primary-expression before ‘>’ token
   39 |         thrd_ = std::shared_ptr<std::thread>(do_not_resolve ? 0 : new std::thread(&name_res::thread_proc, this));
      |                                            ^
src/name_res.cpp: In member function ‘std::string nettop::name_res::to_str(const addr_t&)’:
src/name_res.cpp:45:14: error: ‘thrd_’ was not declared in this scope
   45 |         if (!thrd_)
      |              ^~~~~
src/name_res.cpp: In destructor ‘nettop::name_res::~name_res()’:
src/name_res.cpp:60:12: error: ‘thrd_’ was not declared in this scope
   60 |         if(thrd_)
      |            ^~~~~
make: *** [Makefile:39: obj/name_res.o] Error 1

Is the problem on my side? If not, could you please help compiling it?

Thanks!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.