Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
dcdb
dcdb
Commits
bb150e59
Commit
bb150e59
authored
Jun 12, 2020
by
Alessio Netti
Browse files
ProcFS: minor fixes to overflow handling
parent
84912da1
Changes
1
Hide whitespace changes
Inline
Side-by-side
dcdbpusher/sensors/procfs/ProcfsParser.cpp
View file @
bb150e59
...
...
@@ -629,7 +629,7 @@ bool SARParser::_readMetrics() {
if
(
_latestBuffer
>=
_columnRawReadings
[(
lineCtr
-
1
)
*
DEFAULTMETRICS
+
colCtr
])
_latestValue
=
_latestBuffer
-
_columnRawReadings
[(
lineCtr
-
1
)
*
DEFAULTMETRICS
+
colCtr
];
else
return
false
;
_latestValue
=
_latestBuffer
+
(
ULLONG_MAX
-
_columnRawReadings
[(
lineCtr
-
1
)
*
DEFAULTMETRICS
+
colCtr
])
;
_columnRawReadings
[(
lineCtr
-
1
)
*
DEFAULTMETRICS
+
colCtr
]
=
_latestBuffer
;
_accumulators
[
accIdx
]
+=
_latestValue
;
// Second part of the if: if the line contains node-level CPU metrics (starts with "cpu") and the
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment