diff --git a/src/bin/init/main.c b/src/bin/init/main.c index ef373a2..8eb77ec 100755 --- a/src/bin/init/main.c +++ b/src/bin/init/main.c @@ -43,8 +43,6 @@ if (!fork()) { exec("shell"); printf("Error Starting Shell\n"); - //while(1); } - //while(1); exit(1); } \ No newline at end of file diff --git a/src/bin/test/main.c b/src/bin/test/main.c index 014b381..4a120e2 100755 --- a/src/bin/test/main.c +++ b/src/bin/test/main.c @@ -30,11 +30,25 @@ } int main() { - int i = 0; + int i = 0,x = 0,cPid = 0; printf("This Is A Test Program\n"); - for (i=0;i<10;i++) { - printf("%i",i); + printf("My PID Is : [%i]\n",getpid()); + printf("I'm Now Going To Fork Myself And See If This Causes A Memory Leak\n"); + for (i=0;i<=10;i++) { + cPid = fork(); + if (!cPid) { + printf("Child Pid: [%i]\n",getpid()); + for (x=0;x<=10;x++) { + printf("[%i]",x); + } + printf("\n"); + exit(1); + } + else { + printf("Parent Pid: [%i]\n",getpid()); + while (pidStatus(cPid)); + } } - printf("\nTest Complete\n"); + printf("Testing Complete\n"); exit(1); } diff --git a/ubixos.kdevprj b/ubixos.kdevprj index 3cac7b4..f54d7df 100755 --- a/ubixos.kdevprj +++ b/ubixos.kdevprj @@ -426,10 +426,16 @@ type=SOURCE [src/sys/include/Makefile.am] -files=src/sys/include/stdarg.h +files=src/sys/include/stdarg.h,src/sys/include/config.h,src/sys/include/types.h sub_dirs=ubixos,version,drivers,vmm,ubixfs type=normal +[src/sys/include/config.h] +dist=true +install=false +install_location= +type=HEADER + [src/sys/include/drivers/8259.h] dist=true install=false @@ -465,6 +471,12 @@ install_location= type=HEADER +[src/sys/include/types.h] +dist=true +install=false +install_location= +type=HEADER + [src/sys/include/ubixfs/Makefile.am] files=src/sys/include/ubixfs/ubixfs.h,src/sys/include/ubixfs/file.h sub_dirs=