opennebula-5.2.0-fixdisksnapshots.diff
opennebula-5.2.0-fixdisksnapshots/src/vm/Snapshots.cc 2016-10-28 17:50:03.895133797 -0500 | ||
---|---|---|
47 | 47 |
if (this != &s) |
48 | 48 |
{ |
49 | 49 |
next_snapshot = s.next_snapshot; |
50 |
active = s.active;
|
|
50 |
active = -1;
|
|
51 | 51 |
disk_id = s.disk_id; |
52 | 52 | |
53 | 53 |
snapshot_template = s.snapshot_template; |
... | ... | |
96 | 96 | |
97 | 97 |
snap[i]->vector_value("ACTIVE", current); |
98 | 98 | |
99 |
if (current) |
|
100 |
{ |
|
101 |
active = id; |
|
102 |
} |
|
103 | ||
104 | 99 |
if (id >= next_snapshot) |
105 | 100 |
{ |
106 | 101 |
next_snapshot = id + 1; |
... | ... | |
223 | 218 | |
224 | 219 |
int Snapshots::active_snapshot(int id) |
225 | 220 |
{ |
221 |
return 0; |
|
226 | 222 |
if (static_cast<int>(id) == active) |
227 | 223 |
{ |
228 | 224 |
return 0; |