()
| 169 | } |
| 170 | |
| 171 | func (st *StateTransition) preCheck() error { |
| 172 | // Make sure this transaction's nonce is correct. |
| 173 | if st.msg.CheckNonce() { |
| 174 | nonce := st.state.GetNonce(st.msg.From()) |
| 175 | if nonce < st.msg.Nonce() { |
| 176 | return ErrNonceTooHigh |
| 177 | } else if nonce > st.msg.Nonce() { |
| 178 | return ErrNonceTooLow |
| 179 | } |
| 180 | } |
| 181 | return st.buyGas() |
| 182 | } |
| 183 | |
| 184 | // TransitionDb will transition the state by applying the current message and |
| 185 | // returning the result including the the used gas. It returns an error if it |
no test coverage detected