Check if str is really xml before parsing as xml