[FFmpeg-devel] [PATCH/RFC] Prefer getaddrinfo over gethostbyname

Måns Rullgård mans
Fri Jan 8 10:44:31 CET 2010


Martin Storsj? <martin at martin.st> writes:

> On Fri, 8 Jan 2010, M?ns Rullg?rd wrote:
>
>> > From 4401515fe5b291d1773533092f24fe4a057a50bd Mon Sep 17 00:00:00 2001
>> > From: Martin Storsjo <martin at martin.st>
>> > Date: Mon, 4 Jan 2010 00:19:24 +0200
>> > Subject: [PATCH 3/8] Make check_type handle type names containing spaces
>> >
>> > ---
>> >  configure |    3 ++-
>> >  1 files changed, 2 insertions(+), 1 deletions(-)
>> >
>> > diff --git a/configure b/configure
>> > index f120936..810cec8 100755
>> > --- a/configure
>> > +++ b/configure
>> > @@ -735,6 +735,7 @@ check_type(){
>> >      log check_type "$@"
>> >      headers=$1
>> >      type=$2
>> > +    type_quoted=$(echo "$type" | sed 's/ /_/g')
>> >      shift 2
>> >      disable $type
>> 
>> You missed one.
>
> Missed one of what?

The disable line.

>> >      incs=""
>> > @@ -742,7 +743,7 @@ check_type(){
>> >          incs="$incs
>> >  #include <$hdr>"
>> >      done
>> > -    check_cc "$@" <<EOF && enable $type
>> > +    check_cc "$@" <<EOF && enable $type_quoted
>> >  $incs
>> >  $type v;
>> >  EOF
>> 
>> Use enable_safe/disable_safe instead.  They do the required
>> replacements already.
>
> No, they don't escape spaces at the moment:
>
>> enable_safe(){
>>     enable $(echo "$*" | sed 's/[^A-Za-z0-9_ ]/_/g')
>> }
>
> And if they were made to do that, enabling more than one item at a time 
> would break.

Right... that can be fixed though.  Give me a moment.

-- 
M?ns Rullg?rd
mans at mansr.com



More information about the ffmpeg-devel mailing list