LGTM, thanks
On Fri, Jan 10, 2014 at 12:29 PM, Klaus Aehlig <[email protected]> wrote: > Our design states, that the intent-to-upgrade file contains "the current > version of ganeti, the version to change to, and the process ID". Make the > implementation fit with that design. > > Signed-off-by: Klaus Aehlig <[email protected]> > --- > lib/client/gnt_cluster.py | 7 ++++--- > 1 file changed, 4 insertions(+), 3 deletions(-) > > diff --git a/lib/client/gnt_cluster.py b/lib/client/gnt_cluster.py > index c28936b..05f3eeb 100644 > --- a/lib/client/gnt_cluster.py > +++ b/lib/client/gnt_cluster.py > @@ -1786,10 +1786,10 @@ def _ReadIntentToUpgrade(): > > contentstring = utils.ReadFile(pathutils.INTENT_TO_UPGRADE) > contents = utils.UnescapeAndSplit(contentstring) > - if len(contents) != 2: > + if len(contents) != 3: > # file syntactically mal-formed > return None > - return contents[0] > + return contents[1] > > > def _WriteIntentToUpgrade(version): > @@ -1800,7 +1800,8 @@ def _WriteIntentToUpgrade(version): > > """ > utils.WriteFile(pathutils.INTENT_TO_UPGRADE, > - data=utils.EscapeAndJoin([version, "%d" % os.getpid()])) > + data=utils.EscapeAndJoin([constants.RELEASE_VERSION, > version, > + "%d" % os.getpid()])) > > > def _UpgradeBeforeConfigurationChange(versionstring): > -- > 1.8.5.1 > >
