You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
varB64=function(n,x){if(n===7){returnx.lo&0xFF;}varbits=(7-n)*8;if(bits>=32){//faster than >= 32return(x.hi>>>(bits-32))&0xFF;}else{varbitsOff32=32-bits,toMoveDown=this.hi<<bitsOff32>>>bitsOff32;return(x.lo>>>bits|(toMoveDown<<bitsOff32))&0xFF;}}
On line 1079 there is reference to this.hi. In this context, this refers to the object that this function belongs to, but I don't think hi is ever defined there. So the value of this.hi is always undefined.
This means that toMoveDown = this.hi << bitsOff32 >>> bitsOff32; will always be 0.
Is this intended or a bug?
The text was updated successfully, but these errors were encountered:
AndreasGassmann
changed the title
Question about one of the
Question about one of the functions
Nov 5, 2019
AndreasGassmann
changed the title
Question about one of the functions
Value in expression is always undefined
Nov 5, 2019
During a review of our dependencies, we noticed this snippet here: https://github.com/QuantumExplorer/groestl-hash-js/blob/master/lib/groestl.js#L1079
On line 1079 there is reference to
this.hi
. In this context,this
refers to the object that this function belongs to, but I don't thinkhi
is ever defined there. So the value ofthis.hi
is alwaysundefined
.This means that
toMoveDown = this.hi << bitsOff32 >>> bitsOff32;
will always be 0.Is this intended or a bug?
The text was updated successfully, but these errors were encountered: