Update RPM specs to v. 2014.1.1
[openstack-build/neutron-build.git] / rpm / SOURCES / 0002-Remove-dnsmasq-version-warning.patch
1 From 9ca90822cdaef5ef102d953a5cc59c5ed1eb4aa6 Mon Sep 17 00:00:00 2001
2 From: Terry Wilson <twilson@redhat.com>
3 Date: Fri, 13 Dec 2013 09:41:43 -0600
4 Subject: [PATCH] Remove dnsmasq version warning
5
6 ---
7  neutron/agent/linux/dhcp.py | 11 +++++++----
8  1 file changed, 7 insertions(+), 4 deletions(-)
9
10 diff --git a/neutron/agent/linux/dhcp.py b/neutron/agent/linux/dhcp.py
11 index e650c00..fdac998 100644
12 --- a/neutron/agent/linux/dhcp.py
13 +++ b/neutron/agent/linux/dhcp.py
14 @@ -286,10 +286,13 @@ class Dnsmasq(DhcpLocalProcess):
15              ver = re.findall("\d+.\d+", out)[0]
16              is_valid_version = float(ver) >= cls.MINIMUM_VERSION
17              if not is_valid_version:
18 -                LOG.warning(_('FAILED VERSION REQUIREMENT FOR DNSMASQ. '
19 -                              'DHCP AGENT MAY NOT RUN CORRECTLY! '
20 -                              'Please ensure that its version is %s '
21 -                              'or above!'), cls.MINIMUM_VERSION)
22 +                if float(ver) < 2.48:
23 +                    LOG.warning(_('FAILED VERSION REQUIREMENT FOR DNSMASQ. '
24 +                                  'DHCP AGENT MAY NOT RUN CORRECTLY! '
25 +                                  'Please ensure that its version is %s '
26 +                                  'or above!'), cls.MINIMUM_VERSION)
27 +                else:
28 +                    LOG.info(_('dnsmasq version: %s'), ver)
29          except (OSError, RuntimeError, IndexError, ValueError):
30              LOG.warning(_('Unable to determine dnsmasq version. '
31                            'Please ensure that its version is %s '