diff --git a/btcjson/chainsvrresults.go b/btcjson/chainsvrresults.go index 8062d9d9905..7b771b12f72 100644 --- a/btcjson/chainsvrresults.go +++ b/btcjson/chainsvrresults.go @@ -11,8 +11,8 @@ import ( "github.com/btcsuite/btcd/chaincfg/chainhash" - "github.com/btcsuite/btcd/wire" "github.com/btcsuite/btcd/btcutil" + "github.com/btcsuite/btcd/wire" ) // GetBlockHeaderVerboseResult models the data from the getblockheader command when @@ -172,12 +172,13 @@ type SoftForkDescription struct { // Bip9SoftForkDescription describes the current state of a defined BIP0009 // version bits soft-fork. type Bip9SoftForkDescription struct { - Status string `json:"status"` - Bit uint8 `json:"bit"` - StartTime1 int64 `json:"startTime"` - StartTime2 int64 `json:"start_time"` - Timeout int64 `json:"timeout"` - Since int32 `json:"since"` + Status string `json:"status"` + Bit uint8 `json:"bit"` + StartTime1 int64 `json:"startTime"` + StartTime2 int64 `json:"start_time"` + Timeout int64 `json:"timeout"` + Since int32 `json:"since"` + MinActivationHeight int32 `json:"min_activation_height"` } // StartTime returns the starting time of the softfork as a Unix epoch. diff --git a/rpcserver.go b/rpcserver.go index 8c4b7652665..e000af5a4f0 100644 --- a/rpcserver.go +++ b/rpcserver.go @@ -1297,10 +1297,11 @@ func handleGetBlockChainInfo(s *rpcServer, cmd interface{}, closeChan <-chan str endTime = ender.EndTime().Unix() } chainInfo.SoftForks.Bip9SoftForks[forkName] = &btcjson.Bip9SoftForkDescription{ - Status: strings.ToLower(statusString), - Bit: deploymentDetails.BitNumber, - StartTime2: startTime, - Timeout: endTime, + Status: strings.ToLower(statusString), + Bit: deploymentDetails.BitNumber, + StartTime2: startTime, + Timeout: endTime, + MinActivationHeight: int32(deploymentDetails.MinActivationHeight), } }