Laughing1599 / cocoa-rest-client

Automatically exported from code.google.com/p/cocoa-rest-client
Other
0 stars 0 forks source link

Response body gets "fixed" for xml responses #34

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Make request
2. Read output
3. Get confused

What is the expected output? What do you see instead?
When making the request though curl i det this response.

MULTIPLEdk<wtf><?xml version='1.0' encoding='utf-8'?>
<response>
....
</response>

Observe that there is a string there that is not xml and an unclosed <wtf>-tag.

cocoa-rest-client gives me this response:
<wtf>
    <response>
....
    </response>
</wtf>

The wft tag has been fixed. And none xml-data has been stripped. Including the 
xml-declaration.

What version of the product are you using? On what operating system?
Mac osx 1.8.4 and 1.3.5(10) of cocoa rest client.

As i am developing a http-based api with xml-responses  this is a huge issue 
for me and it makes it impossible to use cocoa-rest-client as tool for testing 
as is cannot trust its output.

Original issue reported on code.google.com by nassoZe...@gmail.com on 13 Jun 2013 at 9:34

GoogleCodeExporter commented 8 years ago
I see what the problem is: I passed a tidy XML option to the parser which 
automatically tries to clean up bad XML. This will be fixed in the next 
release. Funny, this code has been in the project for almost 3 years without a 
bug reported. Thanks for catching this. 

Original comment by mike.mat...@gmail.com on 13 Jun 2013 at 11:46

GoogleCodeExporter commented 8 years ago
Yeah. Very weird that this hasn't been reported before. Maybe most people are 
just using the application to test working apis that don't have broken xml.

Anyway, thanks for fixing this!

Original comment by nassoZe...@gmail.com on 19 Jun 2013 at 8:59

GoogleCodeExporter commented 8 years ago

Original comment by mike.mat...@gmail.com on 29 Jun 2013 at 8:35