|
|
@ -46,7 +46,7 @@ bool ProcessEnumerator::findProcessess()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
DIR *dir_p;
|
|
|
|
DIR *dir_p;
|
|
|
|
struct dirent *dir_entry_p;
|
|
|
|
struct dirent *dir_entry_p;
|
|
|
|
|
|
|
|
/*
|
|
|
|
Process *p = 0;
|
|
|
|
Process *p = 0;
|
|
|
|
p = new Process(d->meminfo->meminfo);
|
|
|
|
p = new Process(d->meminfo->meminfo);
|
|
|
|
if(p->isIdentified())
|
|
|
|
if(p->isIdentified())
|
|
|
@ -58,7 +58,7 @@ bool ProcessEnumerator::findProcessess()
|
|
|
|
delete p;
|
|
|
|
delete p;
|
|
|
|
p = 0;
|
|
|
|
p = 0;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
/*
|
|
|
|
*/
|
|
|
|
// Open /proc/ directory
|
|
|
|
// Open /proc/ directory
|
|
|
|
dir_p = opendir("/proc/");
|
|
|
|
dir_p = opendir("/proc/");
|
|
|
|
// Reading /proc/ entries
|
|
|
|
// Reading /proc/ entries
|
|
|
@ -69,7 +69,7 @@ bool ProcessEnumerator::findProcessess()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
continue;
|
|
|
|
continue;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
Process *p2 = new NormalProcess(atoi(dir_entry_p->d_name),d->meminfo->meminfo);
|
|
|
|
Process *p2 = new Process(atoi(dir_entry_p->d_name),d->meminfo->meminfo);
|
|
|
|
if(p2->isIdentified())
|
|
|
|
if(p2->isIdentified())
|
|
|
|
{
|
|
|
|
{
|
|
|
|
d->processes.push_back(p2);
|
|
|
|
d->processes.push_back(p2);
|
|
|
@ -79,6 +79,7 @@ bool ProcessEnumerator::findProcessess()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
delete p2;
|
|
|
|
delete p2;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
/*
|
|
|
|
Process *p3 = new WineProcess(atoi(dir_entry_p->d_name),d->meminfo->meminfo);
|
|
|
|
Process *p3 = new WineProcess(atoi(dir_entry_p->d_name),d->meminfo->meminfo);
|
|
|
|
if(p3->isIdentified())
|
|
|
|
if(p3->isIdentified())
|
|
|
|
{
|
|
|
|
{
|
|
|
@ -89,9 +90,10 @@ bool ProcessEnumerator::findProcessess()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
delete p3;
|
|
|
|
delete p3;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
*/
|
|
|
|
}
|
|
|
|
}
|
|
|
|
closedir(dir_p);
|
|
|
|
closedir(dir_p);
|
|
|
|
*/
|
|
|
|
|
|
|
|
// return value depends on if we found some DF processes
|
|
|
|
// return value depends on if we found some DF processes
|
|
|
|
if(d->processes.size())
|
|
|
|
if(d->processes.size())
|
|
|
|
{
|
|
|
|
{
|
|
|
|