Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Leap:15.0:Rings:1-MinimalX
procinfo
procinfo-sysconf.dif
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File procinfo-sysconf.dif of Package procinfo
--- procinfo.c | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) --- procinfo.c +++ procinfo.c 2004-01-17 07:01:16.000000000 +0000 @@ -1058,19 +1058,7 @@ main (int ac, char **av) } /* Count number of CPUs */ - cpuinfofp = myfopen (PROC_DIR "cpuinfo"); - if (cpuinfofp) { - while (fgets (line, sizeof (line), cpuinfofp)) - if (!strncmp ("processor", line, 9)) /* intel */ - nr_cpus++; - else if (!strncmp ("ncpus ", line, 6)) /* sparc */ - nr_cpus = atoi(line+19); - else if (!strncmp ("cpus detected", line, 13)) /* alpha */ - nr_cpus = atoi(line+27); - fclose (cpuinfofp); - } - if (nr_cpus == 0) - nr_cpus = 1; + nr_cpus = sysconf (_SC_NPROCESSORS_ONLN); /* Gets called from winsz(), but in case stdout is redirected: */ version = make_version (versionfp);
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor