core-lightning/wire
Vasil Dimov 89ceb273f5 wire: remove towire_double()
Before this patch we used to send `double`s over the wire by just
copying them. This is not portable because the internal represenation
of a `double` is implementation specific.

Instead of this, multiply any floating-point numbers that come from
the outside (e.g. JSONs) by 1 million and round them to integers when
handling them.

* Introduce a new param_millionths() that expects a floating-point
  number and returns it multipled by 1000000 as an integer.

* Replace param_double() and param_percent() with param_millionths()

* Previously the riskfactor would be allowed to be negative, which must
  have been unintentional. This patch changes that to require a
  non-negative number.

Changelog-None
2020-02-27 09:07:04 +10:30
..
test Add missing extern qualifiers for gcc 10 2020-02-02 12:59:17 +10:30
common_wire_csv wire: Add common messages that are independent of daemons 2020-01-28 23:50:52 +01:00
extracted_onion_wire_csv Protocol: make var_onion, payment_secret and basic_mpp non-EXPERIMENTAL. 2019-12-12 22:16:03 +01:00
extracted_peer_wire_csv connectd: add network to init message 2019-11-29 21:17:08 +01:00
fromwire.c wire: remove towire_double() 2020-02-27 09:07:04 +10:30
Makefile wire: Add common messages that are independent of daemons 2020-01-28 23:50:52 +01:00
onion_defs.h wire: add onion_defs.h to bolt-check, update quote. 2018-09-13 17:38:13 -07:00
peer_wire.c common/gossip_store: handle timestamp filtering. 2019-06-04 01:29:39 +00:00
peer_wire.h chainparams: Move the BOLT2 quote to the chainparams where we set it 2018-09-14 21:18:11 +02:00
tlvstream.h wire: Remove unused fromwire_tlvs 2019-12-03 00:37:15 +00:00
towire.c wire: remove towire_double() 2020-02-27 09:07:04 +10:30
wire_io.c Remove tal_len, use tal_count() or tal_bytelen(). 2018-07-30 11:31:17 +02:00
wire_io.h gossipd: make more compact getchannels entries. 2019-04-09 12:37:16 -07:00
wire_sync.c Remove tal_len, use tal_count() or tal_bytelen(). 2018-07-30 11:31:17 +02:00
wire_sync.h wire_sync_write: support take() 2017-06-27 10:25:53 +09:30
wire.h wire: remove towire_double() 2020-02-27 09:07:04 +10:30