Branch: refs/heads/master
  Home:   https://github.com/conformal/btcec
  Commit: 218906a91edc77ede1edabf0d070099015b3e65e
      
https://github.com/conformal/btcec/commit/218906a91edc77ede1edabf0d070099015b3e65e
  Author: Dave Collins <[email protected]>
  Date:   2014-02-13 (Thu, 13 Feb 2014)

  Changed paths:
    M btcec.go
    M test_coverage.txt

  Log Message:
  -----------
  Make the race detect happy.

Since the Z values are normalized (which ordinarily mutates them as
needed) before checking for equality, the race detector gets confused when
using a global value for the field representation of the value 1 and
passing it into the various internal arithmetic routines and reports a
false positive.

Even though the race was a false positive and had no adverse effects, this
commit silences the race detector by creating new variables at the top
level and passing them instead of the global fieldOne variable.  The
global is still used for comparison operations since those have no
potential to mutate the value and hence don't trigger the race detector.


Reply via email to