[FFmpeg-devel] [PATCH] Handling special characters in a URL.

Senthilnathan Maadasamy senthilnathan.maadasamy at gmail.com
Mon Mar 4 02:00:03 CET 2013


On Sat, Mar 2, 2013 at 2:35 AM, Michael Niedermayer <michaelni at gmx.at>wrote:

> On Fri, Mar 01, 2013 at 08:02:44AM +0530, Senthilnathan Maadasamy wrote:
> > On Fri, Mar 1, 2013 at 7:49 AM, Michael Niedermayer <michaelni at gmx.at
> >wrote:
>
+static void percent_encode_url(char *component, size_t component_size = 0,
> +                               const char *allowed)
> +{
> +    char enc[MAX_URL_SIZE], c;
> +    int enc_len = 0;
> +    char *src = component;
> +
> +    if (!src) return;
> +
>
> +    while (c = *src) {
>
> accesses out of array, src is 0 elements large so any access must be
> outside
>
> i dont know if this is the only case where this happens

Agreed.  This can also happen in some cases where component_size != 0.
 Fixed and attached the patch.

Thanks,
Senthil
-------------- next part --------------
A non-text attachment was scrubbed...
Name: special-characters-in-URL.patch
Type: application/octet-stream
Size: 2830 bytes
Desc: not available
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20130304/94d2bbb6/attachment.obj>


More information about the ffmpeg-devel mailing list