How to solve general imput/output error when opening .xls files that are badly formatted ?

The extension is xls but the format is xml. If I open it with excel 2007 it gives me the message about the difference between extension and format. After I save it as xls I can open it using LibreOffice with no hassle. At the present time I upload the file in Drive, I download it on the windows machine, I open and save it as xls, I upload it again, I download it on the Linux machine and after that I can use it. I have no way to install MS Office on the linux machine.

Thank you