added initial piece of error handling code...

Signed-off-by: msperl <msperl@server>