mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-01-18 05:12:45 +01:00
Sort include lines (ignoring hacky cli test utils).
Put ccan first, openssl next, then standard headers, then locals. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
parent
4e8eda47a1
commit
ef9463f6b1
8
anchor.c
8
anchor.c
@ -1,11 +1,11 @@
|
||||
#include <ccan/err/err.h>
|
||||
#include "anchor.h"
|
||||
#include "bitcoin/pubkey.h"
|
||||
#include "bitcoin/script.h"
|
||||
#include "bitcoin/tx.h"
|
||||
#include "overflows.h"
|
||||
#include "pkt.h"
|
||||
#include "permute_tx.h"
|
||||
#include "bitcoin/script.h"
|
||||
#include "bitcoin/pubkey.h"
|
||||
#include <ccan/err/err.h>
|
||||
#include "pkt.h"
|
||||
#include "protobuf_convert.h"
|
||||
|
||||
struct bitcoin_tx *anchor_tx_create(const tal_t *ctx,
|
||||
|
@ -1,6 +1,6 @@
|
||||
#include <ccan/crypto/sha256/sha256.h>
|
||||
#include "address.h"
|
||||
#include "pubkey.h"
|
||||
#include <ccan/crypto/sha256/sha256.h>
|
||||
|
||||
void bitcoin_address(const struct pubkey *key, struct bitcoin_address *addr)
|
||||
{
|
||||
|
@ -1,7 +1,7 @@
|
||||
#ifndef LIGHTNING_BITCOIN_ADDRESS_H
|
||||
#define LIGHTNING_BITCOIN_ADDRESS_H
|
||||
#include <openssl/ripemd.h>
|
||||
#include <ccan/short_types/short_types.h>
|
||||
#include <openssl/ripemd.h>
|
||||
|
||||
struct pubkey;
|
||||
|
||||
|
@ -3,16 +3,16 @@
|
||||
// Copyright (c) 2009-2012 The Bitcoin Developers
|
||||
// Distributed under the MIT/X11 software license, see the accompanying
|
||||
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
|
||||
#include "base58.h"
|
||||
#include "shadouble.h"
|
||||
#include "address.h"
|
||||
#include "pubkey.h"
|
||||
#include <assert.h>
|
||||
#include <ccan/build_assert/build_assert.h>
|
||||
#include <ccan/tal/str/str.h>
|
||||
#include <openssl/obj_mac.h>
|
||||
#include <openssl/sha.h>
|
||||
#include <assert.h>
|
||||
#include <string.h>
|
||||
#include "address.h"
|
||||
#include "base58.h"
|
||||
#include "pubkey.h"
|
||||
#include "shadouble.h"
|
||||
|
||||
static const char enc_16[] = "0123456789abcdef";
|
||||
static const char enc_58[] =
|
||||
|
@ -1,8 +1,8 @@
|
||||
#ifndef LIGHTNING_BITCOIN_BASE58_H
|
||||
#define LIGHTNING_BITCOIN_BASE58_H
|
||||
/* FIXME: Use libsecpk1 */
|
||||
#include <ccan/tal/tal.h>
|
||||
#include <ccan/short_types/short_types.h>
|
||||
#include <ccan/tal/tal.h>
|
||||
#include <openssl/bn.h>
|
||||
#include <openssl/ec.h>
|
||||
#include <openssl/ripemd.h>
|
||||
|
@ -1,7 +1,7 @@
|
||||
#include "pubkey.h"
|
||||
#include <openssl/ecdsa.h>
|
||||
#include <ccan/str/hex/hex.h>
|
||||
#include <openssl/ecdsa.h>
|
||||
#include <assert.h>
|
||||
#include "pubkey.h"
|
||||
|
||||
/* Must agree on key validity with bitcoin! Stolen from bitcoin/src/pubkey.h's
|
||||
* GetLen:
|
||||
|
@ -1,11 +1,11 @@
|
||||
#include "script.h"
|
||||
#include "address.h"
|
||||
#include "signature.h"
|
||||
#include "pubkey.h"
|
||||
#include <openssl/ripemd.h>
|
||||
#include <ccan/endian/endian.h>
|
||||
#include <ccan/crypto/sha256/sha256.h>
|
||||
#include <ccan/endian/endian.h>
|
||||
#include <openssl/ripemd.h>
|
||||
#include <assert.h>
|
||||
#include "address.h"
|
||||
#include "pubkey.h"
|
||||
#include "script.h"
|
||||
#include "signature.h"
|
||||
|
||||
/* Some standard ops */
|
||||
#define OP_PUSHBYTES(val) (val)
|
||||
|
@ -1,6 +1,5 @@
|
||||
#ifndef LIGHTNING_BITCOIN_SHADOUBLE_H
|
||||
#define LIGHTNING_BITCOIN_SHADOUBLE_H
|
||||
#include "config.h"
|
||||
#include <ccan/crypto/sha256/sha256.h>
|
||||
|
||||
/* To explicitly distinguish between single sha and bitcoin's standard double */
|
||||
|
@ -1,12 +1,12 @@
|
||||
#include "signature.h"
|
||||
#include "shadouble.h"
|
||||
#include "tx.h"
|
||||
#include <ccan/cast/cast.h>
|
||||
#include "pubkey.h"
|
||||
#include "script.h"
|
||||
#include "shadouble.h"
|
||||
#include "signature.h"
|
||||
#include "tx.h"
|
||||
#include <openssl/bn.h>
|
||||
#include <openssl/obj_mac.h>
|
||||
#include <assert.h>
|
||||
#include <ccan/cast/cast.h>
|
||||
|
||||
#undef DEBUG
|
||||
#ifdef DEBUG
|
||||
|
@ -1,8 +1,8 @@
|
||||
#ifndef LIGHTNING_BITCOIN_SIGNATURE_H
|
||||
#define LIGHTNING_BITCOIN_SIGNATURE_H
|
||||
#include <ccan/short_types/short_types.h>
|
||||
#include <openssl/ecdsa.h>
|
||||
#include <ccan/tal/tal.h>
|
||||
#include <openssl/ecdsa.h>
|
||||
|
||||
enum sighash_type {
|
||||
SIGHASH_ALL = 1,
|
||||
|
@ -1,10 +1,10 @@
|
||||
#include "tx.h"
|
||||
#include <ccan/crypto/sha256/sha256.h>
|
||||
#include <ccan/err/err.h>
|
||||
#include <ccan/tal/grab_file/grab_file.h>
|
||||
#include <ccan/str/hex/hex.h>
|
||||
#include <ccan/endian/endian.h>
|
||||
#include <ccan/err/err.h>
|
||||
#include <ccan/str/hex/hex.h>
|
||||
#include <ccan/tal/grab_file/grab_file.h>
|
||||
#include <assert.h>
|
||||
#include "tx.h"
|
||||
|
||||
static void add_varint(varint_t v,
|
||||
void (*add)(const void *, size_t, void *), void *addp)
|
||||
|
@ -1,9 +1,9 @@
|
||||
#include "close_tx.h"
|
||||
#include "bitcoin/pubkey.h"
|
||||
#include "bitcoin/script.h"
|
||||
#include "bitcoin/shadouble.h"
|
||||
#include "bitcoin/tx.h"
|
||||
#include "bitcoin/script.h"
|
||||
#include "close_tx.h"
|
||||
#include "permute_tx.h"
|
||||
#include "bitcoin/pubkey.h"
|
||||
#include "pkt.h"
|
||||
#include "protobuf_convert.h"
|
||||
|
||||
|
@ -1,9 +1,9 @@
|
||||
#include "commit_tx.h"
|
||||
#include "bitcoin/pubkey.h"
|
||||
#include "bitcoin/script.h"
|
||||
#include "bitcoin/shadouble.h"
|
||||
#include "bitcoin/tx.h"
|
||||
#include "bitcoin/script.h"
|
||||
#include "commit_tx.h"
|
||||
#include "permute_tx.h"
|
||||
#include "bitcoin/pubkey.h"
|
||||
#include "pkt.h"
|
||||
#include "protobuf_convert.h"
|
||||
|
||||
|
@ -1,9 +1,9 @@
|
||||
#include "find_p2sh_out.h"
|
||||
#include "bitcoin/tx.h"
|
||||
#include "bitcoin/script.h"
|
||||
#include <string.h>
|
||||
#include <ccan/err/err.h>
|
||||
#include <ccan/tal/tal.h>
|
||||
#include <string.h>
|
||||
#include "bitcoin/script.h"
|
||||
#include "bitcoin/tx.h"
|
||||
#include "find_p2sh_out.h"
|
||||
|
||||
u32 find_p2sh_out(const struct bitcoin_tx *tx, u8 *redeemscript)
|
||||
{
|
||||
|
@ -1,7 +1,7 @@
|
||||
#include "permute_tx.h"
|
||||
#include <ccan/crypto/sha256/sha256.h>
|
||||
#include <stdbool.h>
|
||||
#include <string.h>
|
||||
#include "permute_tx.h"
|
||||
|
||||
static u32 get_next_rand(struct sha256 *h, size_t *randidx)
|
||||
{
|
||||
|
6
pkt.c
6
pkt.c
@ -1,11 +1,11 @@
|
||||
#include <ccan/crypto/sha256/sha256.h>
|
||||
#include <ccan/tal/grab_file/grab_file.h>
|
||||
#include <ccan/err/err.h>
|
||||
#include "pkt.h"
|
||||
#include "bitcoin/tx.h"
|
||||
#include <ccan/tal/grab_file/grab_file.h>
|
||||
#include "bitcoin/address.h"
|
||||
#include "bitcoin/pubkey.h"
|
||||
#include "bitcoin/signature.h"
|
||||
#include "bitcoin/tx.h"
|
||||
#include "pkt.h"
|
||||
#include "protobuf_convert.h"
|
||||
|
||||
static struct pkt *to_pkt(const tal_t *ctx, Pkt__PktCase type, void *msg)
|
||||
|
2
pkt.h
2
pkt.h
@ -5,10 +5,10 @@
|
||||
* This could be a simple set of macros, if the protobuf-c people hadn't
|
||||
* insisted on "prettifing" the names they generate into CamelCase.
|
||||
*/
|
||||
#include "lightning.pb-c.h"
|
||||
#include <ccan/endian/endian.h>
|
||||
#include <ccan/short_types/short_types.h>
|
||||
#include <ccan/tal/tal.h>
|
||||
#include "lightning.pb-c.h"
|
||||
|
||||
/* A packet, ready to be de-protobuf'ed. */
|
||||
struct pkt {
|
||||
|
@ -1,7 +1,7 @@
|
||||
#include "protobuf_convert.h"
|
||||
#include "bitcoin/signature.h"
|
||||
#include "bitcoin/pubkey.h"
|
||||
#include <ccan/crypto/sha256/sha256.h>
|
||||
#include "bitcoin/pubkey.h"
|
||||
#include "bitcoin/signature.h"
|
||||
#include "protobuf_convert.h"
|
||||
|
||||
Signature *signature_to_proto(const tal_t *ctx, const struct signature *sig)
|
||||
{
|
||||
|
@ -1,8 +1,8 @@
|
||||
#ifndef LIGHTNING_PROTOBUF_CONVERT_H
|
||||
#define LIGHTNING_PROTOBUF_CONVERT_H
|
||||
#include "lightning.pb-c.h"
|
||||
#include <ccan/tal/tal.h>
|
||||
#include <stdbool.h>
|
||||
#include "lightning.pb-c.h"
|
||||
|
||||
/* Convert to-from protobuf to internal representation. */
|
||||
struct signature;
|
||||
|
Loading…
Reference in New Issue
Block a user