You left off the first line(s) of the error message. It would give the name of the exception and maybe some more details.
What you did post shows that your code was creating an ObjectInputStream...