diff options
author | Robert C. Helling <helling@atdotde.de> | 2019-03-18 21:32:14 +0100 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2019-03-18 19:40:32 -0700 |
commit | c7bb67c5bef01772a9e52dddccfa5f02d91393ff (patch) | |
tree | d032174cd0f5206de3063274d6a641a881c1dbe4 /profile-widget/ruleritem.cpp | |
parent | 4524e2b0b39f47996cd8acc0c938c47753f31854 (diff) | |
download | subsurface-c7bb67c5bef01772a9e52dddccfa5f02d91393ff.tar.gz |
Profile: pass by reference rather than by value for large struct
Addresses LGTM.com suggestion.
Signed-off-by: Robert C. Helling <helling@atdotde.de>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'profile-widget/ruleritem.cpp')
-rw-r--r-- | profile-widget/ruleritem.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/profile-widget/ruleritem.cpp b/profile-widget/ruleritem.cpp index 0bcebc4d4..c7b82a3c6 100644 --- a/profile-widget/ruleritem.cpp +++ b/profile-widget/ruleritem.cpp @@ -152,11 +152,11 @@ RulerNodeItem2 *RulerItem2::destNode() const return dest; } -void RulerItem2::setPlotInfo(plot_info info) +void RulerItem2::setPlotInfo(plot_info *info) { - pInfo = info; - dest->setPlotInfo(info); - source->setPlotInfo(info); + pInfo = *info; + dest->setPlotInfo(*info); + source->setPlotInfo(*info); dest->recalculate(); source->recalculate(); recalculate(); |