Browse Source

Ensure store ID parsed from URI is properly encoded

Ensure the store ID parsed from a request URI is unicode. This fixes
a py27 issue that allowed an incorrectly encoded value to be added to
the image's metadata.

Support for py27 is dropped in Ussuri, but this fix is required on
earlier releases that do support py27.

Closes-Bug: #1861501
Change-Id: I5a1c61430879a910e7b6c79effba538431959d56
(cherry picked from commit 8649fdc2a2)
changes/72/705272/1
Alan Bishop 3 weeks ago
parent
commit
c5bdc55366
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      glance/common/store_utils.py

+ 1
- 1
glance/common/store_utils.py View File

@@ -172,7 +172,7 @@ def _get_store_id_from_uri(uri):
break

if url_matched:
return store
return u"%s" % store
else:
LOG.warning("Invalid location uri %s", uri)
return


Loading…
Cancel
Save