Skip to content

[qt] Use maxTxFee instead of 10000000#6951

Merged
jonasschnelli merged 1 commit intobitcoin:masterfrom
maflcko:MarcoFalke-2015-qtMaxFee
Nov 18, 2015
Merged

[qt] Use maxTxFee instead of 10000000#6951
jonasschnelli merged 1 commit intobitcoin:masterfrom
maflcko:MarcoFalke-2015-qtMaxFee

Conversation

@maflcko
Copy link
Copy Markdown
Member

@maflcko maflcko commented Nov 5, 2015

@morcos @laanwj @cozz bitcoin-qt should not ignore the param and use DEFAULT_TRANSACTION_MAXFEE = 0.1 * COIN all the time.

This code behaves exactly the same as the code which got rejected in #6887. (C.f. in-source comment for explanation)

@laanwj
Copy link
Copy Markdown
Member

laanwj commented Nov 9, 2015

utACK

@fanquake
Copy link
Copy Markdown
Member

utACK

@jonasschnelli
Copy link
Copy Markdown
Contributor

Slightly NACK.
CreateTransaction() at L277 (https://github.com/bitcoin/bitcoin/blob/master/src/qt/walletmodel.cpp#L277) will already reduce the fee to maxTxFee (through GetMinimumFee(nBytes, nTxConfirmTarget, mempool)).
Check: https://github.com/bitcoin/bitcoin/blob/master/src/wallet/wallet.cpp#L2144

IMO it's impossible that the changed if triggers (if (nFeeRequired > maxTxFee))).

I think we should remove the if.

The only concern I see – is – if a user sets an absurde fee over the QT send coins UI, lets assume 10.0 BTC per kb (which will be accepted in the input filed), the fee will automatically – without warning or informing – reduced to maxTxFee. A warning or information would be appropriate in this case.

@maflcko
Copy link
Copy Markdown
Member Author

maflcko commented Nov 16, 2015

I think we should remove the if.

@laanwj did not like that.

@jonasschnelli
Copy link
Copy Markdown
Contributor

After reading the ifs comment, I see the purpose of this check. It's a "belt-and-suspenders check".
So, it shouldn't hurt and might protect from insane fees if we once change the wallet layer.

Changed my mind:
Tested ACK.

@jonasschnelli jonasschnelli merged commit 513686d into bitcoin:master Nov 18, 2015
jonasschnelli added a commit that referenced this pull request Nov 18, 2015
513686d [qt] Use maxTxFee instead of 10000000 (MarcoFalke)
@maflcko maflcko deleted the MarcoFalke-2015-qtMaxFee branch November 18, 2015 15:45
@bitcoin bitcoin locked as resolved and limited conversation to collaborators Sep 8, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants