mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
core: remove add_empty_cylinder()
This one-liner wasn't really doing anything and there was only one user of the return value. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
parent
9bb2255ba8
commit
498302dcc6
4 changed files with 4 additions and 10 deletions
|
@ -366,7 +366,7 @@ cylinder_t *dive::get_or_create_cylinder(int idx)
|
|||
return NULL;
|
||||
}
|
||||
while (static_cast<size_t>(idx) >= cylinders.size())
|
||||
add_empty_cylinder(&cylinders);
|
||||
cylinders.emplace_back();
|
||||
return &cylinders[idx];
|
||||
}
|
||||
|
||||
|
@ -1075,7 +1075,7 @@ static void fixup_dc_sample_sensors(struct dive &dive, struct divecomputer &dc)
|
|||
|
||||
// Do we need to add empty cylinders?
|
||||
while (sensor_mask) {
|
||||
add_empty_cylinder(&dive.cylinders);
|
||||
dive.cylinders.emplace_back();
|
||||
sensor_mask >>= 1;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue