/*  This file is part of lsnet. 

    Lsnet is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    Lsnet is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with lsnet.  If not, see <http://www.gnu.org/licenses/>.
*/

//#include <sys/types.h>
//#include <dirent.h>
//#define SIZE2 10000

int processes() {
	DIR *dp;
	struct dirent *ep;
	dp = (opendir ("/proc"));
	int processes = 0;
	int i;
	int success = 1;
	while ((ep = readdir (dp))){		
		for(i=0; i < strlen(ep->d_name)-1; i++) {
			if (      ep->d_name[i] != '0' || ep->d_name[i] != '1' 
                               || ep->d_name[i] != '2' || ep->d_name[i] != '3' 
                               || ep->d_name[i] != '4' || ep->d_name[i] != '5' 
                               || ep->d_name[i] != '6' || ep->d_name[i] != '7' 
                               || ep->d_name[i] != '8' || ep->d_name[i] != '9'
                           ){ 
 
                       		success = 1;

 			}else{
				


		}
		//processes++;

	}
		(void) closedir (dp);
	return (processes);
}

