[dts] [patch V1] alter the regular expression format of hostfwd value

Tu, Lijuan lijuan.tu at intel.com
Wed May 22 10:58:18 CEST 2019


Applied, thanks

> -----Original Message-----
> From: dts [mailto:dts-bounces at dpdk.org] On Behalf Of lihong
> Sent: Monday, May 13, 2019 8:29 AM
> To: dts at dpdk.org
> Cc: Ma, LihongX <lihongx.ma at intel.com>
> Subject: [dts] [patch V1] alter the regular expression format of hostfwd value
> 
> Signed-off-by: lihong <lihongx.ma at intel.com>
> ---
>  framework/qemu_kvm.py | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/framework/qemu_kvm.py b/framework/qemu_kvm.py index
> c3e8f37..80a39c8 100644
> --- a/framework/qemu_kvm.py
> +++ b/framework/qemu_kvm.py
> @@ -562,7 +562,7 @@ class QEMUKvm(VirtBase):
>          Use regular expression to check if hostfwd value format is correct.
>          """
>          regx_ip = '\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}'
> -        regx_hostfwd = r'["tcp" | "udp"]?:%s?:\d+-%s?:\d+' % (regx_ip, regx_ip)
> +        regx_hostfwd = r'(tcp|udp)?:(%s)?:\d+-(%s)?:\d+' % (regx_ip,
> + regx_ip)
>          if not re.match(regx_hostfwd, opt_hostfwd):
>              raise Exception("Option opt_hostfwd format is not correct,\n" +
>                              "it is %s,\n " % opt_hostfwd +
> --
> 2.7.4



More information about the dts mailing list