diff options
| author | Martin Kobetic <mkobetic@gmail.com> | 2014-06-24 14:43:21 +0000 |
|---|---|---|
| committer | Martin Kobetic <mkobetic@gmail.com> | 2014-06-24 15:32:04 +0000 |
| commit | bbee09da308fcc95634a14cde496092b5c676f46 (patch) | |
| tree | fb51f26e53244129bb139c6ce942ae9f2e60e4c0 /db.go | |
| parent | Merge pull request #210 from benbjohnson/default-options (diff) | |
| download | dedo-bbee09da308fcc95634a14cde496092b5c676f46.tar.gz dedo-bbee09da308fcc95634a14cde496092b5c676f46.tar.xz | |
copy receiver stats in Stats.Sub()
Diffstat (limited to 'db.go')
| -rw-r--r-- | db.go | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -575,7 +575,8 @@ type Stats struct { // This is useful when obtaining stats at two different points and time and // you need the performance counters that occurred within that time span. func (s *Stats) Sub(other *Stats) Stats { - var diff Stats + var diff Stats = *s + diff.TxN = other.TxN - s.TxN diff.TxStats = s.TxStats.Sub(&other.TxStats) return diff } |
