Fixed a condition for error return on file put.