[FFmpeg-devel] [PATCH 1/2] configure: add cleanws() function

Janne Grunau janne-ffmpeg
Sun Feb 13 16:47:27 CET 2011


On Sun, Feb 13, 2011 at 01:17:58PM +0000, Mans Rullgard wrote:
> This function removes leading and trailing spaces and collapses
> multiple spaces into one.
> 
> Signed-off-by: Mans Rullgard <mans at mansr.com>
> ---
>  configure |    4 ++++
>  1 files changed, 4 insertions(+), 0 deletions(-)
> 
> diff --git a/configure b/configure
> index a310d25..01b092f 100755
> --- a/configure
> +++ b/configure
> @@ -313,6 +313,10 @@ sh_quote(){
>      echo "$v"
>  }
>  
> +cleanws(){
> +    echo "$@" | sed 's/^ *//;s/  */ /g;s/ *$//'
> +}
> +
>  filter(){
>      pat=$1
>      shift

ok

Janne



More information about the ffmpeg-devel mailing list