Writing byte stream as jpeg format to disk
Grant Edwards
invalid at invalid.invalid
Thu Aug 26 14:35:37 EDT 2010
On 2010-08-26, Navkirat Singh <navkirats at gmail.com> wrote:
>
> On 26-Aug-2010, at 11:01 PM, John Bokma wrote:
>
>> Navkirat Singh <navkirats at gmail.com> writes:
>>
>>> Hey guys,
>>>
>>> I am programming a webserver, I receive a jpeg file with the POST
>>> method.The file (.jpeg) is encoded in bytes, I parse the bytes by
>>> decoding them to a string.
>>
>> Why?
>
> why? I am not quite sure what you have not understood.
You're starting with JPEG data. If you want to write it to a file,
then write it to a file.
Whatever process you're describing as "I parse the bytes by decoding
them to a string" is not needed and is apparently converting the JPEG
data into something that's not JPEG data.
--
Grant Edwards grant.b.edwards Yow! PARDON me, am I
at speaking ENGLISH?
gmail.com
More information about the Python-list
mailing list