ToastFreeware
/
debian
/
cpulimit.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
9fadb6f88a2d65d71541a74b24d444c51d807934
[debian/cpulimit.git]
/
ptest.c
1
#include <stdio.h>
2
#include <sys/types.h>
3
#include <unistd.h>
4
#include <sys/types.h>
5
#include <sys/wait.h>
6
#include "procutils.h"
7
8
//simple program to test cpulimit
9
10
int main()
11
{
12
printf("PID %d\n", getpid());
13
int i;
14
for (i=0;i<10;i++) {
15
if (fork()>0){
16
printf("PID %d\n", getpid());
17
while(1);
18
}
19
}
20
return 0;
21
}