diff --git a/main/views.py b/main/views.py index 2582faa..afa70cf 100755 --- a/main/views.py +++ b/main/views.py @@ -90,7 +90,12 @@ def get_cpus(): pipe = os.popen("cat /proc/cpuinfo |" + "grep 'model name'") data = pipe.read().strip().split(':',2)[-1] pipe.close() - + + if not data: + pipe = os.popen("cat /proc/cpuinfo |" + "grep 'Processor'") + data = pipe.read().strip().split(':',2)[-1] + pipe.close() + cpus = multiprocessing.cpu_count() data = {'cpus': cpus, 'type': data}