Mode this at top of file

This commit is contained in:
6arelyFuture 2022-06-19 17:31:49 +02:00
parent fcb58a709f
commit cb0f1d0d8c
Signed by: Future
GPG Key ID: FA77F074E98D98A5

View File

@ -13,6 +13,13 @@
#define MAX_MEMORY 1048576
#define MAX_TRACK_SIZE 30
struct process_monitor {
int id;
int active;
};
static struct process_monitor processes[MAX_TRACK_SIZE];
FILE* popen(const char* command, const char* type);
int pclose(FILE* stream);
char* strerror(int errnum);
@ -99,13 +106,6 @@ static int is_process_wild(int curr_real_mem, int peak_real_mem,
return 1;
}
struct process_monitor {
int id;
int active;
};
static struct process_monitor processes[MAX_TRACK_SIZE];
int setup(const char* pid) {
char* command = va("pgrep %s", pid);
FILE* file = popen(command, "r");