Made magic-export handle failure more gracefully

* If invalid alias or magic files was defined, all files would be
  emptied excluding the header
* Fix warnings about converting Content object to string

Change-Id: I20aaa93dcc762684ea63c0fef6fb10fa0717e681
Merge "Made magic-export handle failure more gracefully"