improved error handling dramatically; now gives the actual calling function...