Updated main.c

Should now compile and run on Mac OS X as well