File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -382,12 +382,12 @@ module.exports = function buildDecode (decodingTypes) {
382
382
switch ( size ) {
383
383
case 4 :
384
384
// timestamp 32 stores the number of seconds that have elapsed since 1970-01-01 00:00:00 UTC in an 32-bit unsigned integer
385
- seconds = buf . readUInt32BE ( )
385
+ seconds = buf . readUInt32BE ( 0 )
386
386
break
387
387
388
388
case 8 : // Timestamp 64 stores the number of seconds and nanoseconds that have elapsed
389
389
// since 1970-01-01 00:00:00 UTC in 32-bit unsigned integers, split 30/34 bits
390
- var upper = buf . readUInt32BE ( )
390
+ var upper = buf . readUInt32BE ( 0 )
391
391
var lower = buf . readUInt32BE ( 4 )
392
392
nanoseconds = upper / 4
393
393
seconds = ( ( upper & 0x03 ) * Math . pow ( 2 , 32 ) ) + lower // If we use bitwise operators, we get truncated to 32bits
You can’t perform that action at this time.
0 commit comments