I have to use C for one project and I am thinking of using longjmp/setjmp for error handling as I think it will be much easier to handle error in one central pl
longjmp/setjmp
Have a look at this example/tutorial: http://www.di.unipi.it/~nids/docs/longjump_try_trow_catch.html