Closed
Bug 871971
Opened 12 years ago
Closed 12 years ago
MIME type for blob data lost when sent through Datachannel
Categories
(Core :: WebRTC: Networking, defect)
Tracking
()
RESOLVED
INVALID
People
(Reporter: whimboo, Unassigned)
Details
(Keywords: testcase, Whiteboard: [WebRTC])
Attachments
(1 file)
|
9.01 KB,
text/html
|
Details |
Mozilla/5.0 (X11; Linux x86_64; rv:22.0) Gecko/20130512 Firefox/22.0 ID:20130512004015 CSet: 581ea0e6531e
When you send a message of type blob through the datachannel, the MIME type of the blog should be the same on both ends. But on the receiving side it is lost. The type property returns an empty string.
Steps:
1. Load testcase
2. Click start to connect.
3. Select a file to send
4. Click send
After step 4 watch the output window and check that the MIME type of 'file' is lost on the remote side.
Comment 1•12 years ago
|
||
Note that test page in itself is a bit buggy, so we need to double check this reproduces on a different test case.
Comment 2•12 years ago
|
||
Blobs do not retain any metadata when transferred through either WebSockets or DataChannel, and the application has the option of receiving binary data as either a blob or an arraybuffer. Neither is a native JS object-transfer mechanism; if you need to transfer a JS object with all metadata, converting it to JSON might be more appropriate.
An application can separately transfer the type if it needs to in a number of ways (preceding blob with a text or binary metadata datagram, using another channel, transferring the blob in a new DataChannel with the label field used to store the type, etc.)
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → INVALID
| Reporter | ||
Comment 3•12 years ago
|
||
Hm, ok. Sad to hear that. Looks like more work to do for the end-user.
Randell, can we get this documented in the spec? I think that nearly everyone who wants to transfer Blobs or ArrayBuffer will be affected by this the first time. And I haven't seen this on the spec site.
You need to log in
before you can comment on or make changes to this bug.
Description
•