Merge hotfix/2.2.0 back to master (#497)

* Decide version hotfix (#493)

* correct the check for installed version

* add length check to remove_bom

* update version to 2.2.1
This commit is contained in:
Hans Krijger
2016-11-18 15:54:19 -08:00
committed by GitHub
parent 146f430f41
commit 68a18b35d8
3 changed files with 9 additions and 6 deletions
+4 -2
View File
@@ -251,8 +251,10 @@ def set_ini_config(config, name, val):
def remove_bom(c):
if str_to_ord(c[0]) > 128 and str_to_ord(c[1]) > 128 and \
str_to_ord(c[2]) > 128:
if len(c) > 2 \
and str_to_ord(c[0]) > 128 \
and str_to_ord(c[1]) > 128 \
and str_to_ord(c[2]) > 128:
c = c[3:]
return c
+1 -1
View File
@@ -56,7 +56,7 @@ def get_distro():
AGENT_NAME = "WALinuxAgent"
AGENT_LONG_NAME = "Azure Linux Agent"
AGENT_VERSION = '2.2.0'
AGENT_VERSION = '2.2.1'
AGENT_LONG_VERSION = "{0}-{1}".format(AGENT_NAME, AGENT_VERSION)
AGENT_DESCRIPTION = """\
The Azure Linux Agent supports the provisioning and running of Linux
+4 -3
View File
@@ -360,9 +360,10 @@ class ExtHandlerInstance(object):
# Determine the desired and installed versions
requested_version = FlexibleVersion(self.ext_handler.properties.version)
installed_version = FlexibleVersion(self.get_installed_version())
if installed_version is None:
installed_version = requested_version
installed_version_string = self.get_installed_version()
installed_version = requested_version \
if installed_version_string is None \
else FlexibleVersion(installed_version_string)
# Divide packages
# - Find the installed package (its version must exactly match)