Update main.c

allocated arguments for a thread,
disclaimer: not tested, may not work
Merge pull request #1 from liquidblock/patch-1

Update main.c