server/mjpeg_encoder: fix wrong size assigned to dest_len

It should have been the allocated size and not the occupied one.
This led to a lot of unnecessary allocations and deallocations.
This commit is contained in:
Yonit Halperin 2012-05-10 14:01:39 +03:00
parent fecc1e3d4d
commit c211774422

View File

@ -140,7 +140,7 @@ static void term_mem_destination(j_compress_ptr cinfo)
mem_destination_mgr *dest = (mem_destination_mgr *) cinfo->dest;
*dest->outbuffer = dest->buffer;
*dest->outsize = dest->bufsize - dest->pub.free_in_buffer;
*dest->outsize = dest->bufsize;
}
/*