added alloca.h header where necessary