added hand-coded inode-to-process mapping

This commit is contained in:
Arnout Engelen
2005-01-15 12:29:49 +00:00
parent 4a3a21a5df
commit f81fea0805
2 changed files with 199 additions and 0 deletions

16
inode2prog.h Normal file
View File

@@ -0,0 +1,16 @@
/* this should be called quickly after the packet
* arrived, since the inode may disappear from the table
* quickly, too :) */
#include "nethogs.h"
// #define PROGNAME_WIDTH 200
struct prg_node {
long inode;
int pid;
char name[PROGNAME_WIDTH];
};
struct prg_node * findPID (unsigned long inode);
void prg_cache_clear();