tiny file server sample - added some error handling