[CRIU] Re: [PATCH 5/5] syscalls: Complete redesign v7

Pavel Emelyanov xemul at parallels.com
Wed Apr 18 08:17:54 EDT 2012


> +while read line
> +do
> +       line=`echo $line | sed -e 's/^ *//g' | sed -e '/^\#/d' | sed -e 's/\t\{1,\}/|/g'`
> +       if [ -z "$line" ]; then
> +               continue
> +       fi
> +       num=`echo $line | cut -f 1 -d ' '`
> +       lv=`echo $line | cut -f 3 -d ' '`
> +       rv=`echo $line | cut -f 2 -d '('`
> +       echo $line | awk '{ print "#define " $1 " " $2};'       >> $codesout
> +       echo "extern unsigned long $lv ($rv;"                   >> $protosout
> +       echo "SYSCALL($lv,$num)"                                >> $asmout

I thought I told to do it without loops using tree cat | egrep | awk chains, no?

> +done
> +) < $in



More information about the CRIU mailing list