Browse Source

source cleanup: sort include lines into alpha order

This makes merging easier in future.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
ppa-0.6.1
Rusty Russell 9 years ago
parent
commit
9ebbe16b1e
  1. 2
      bitcoin/address.c
  2. 12
      bitcoin/base58.c
  3. 6
      bitcoin/pubkey.c
  4. 8
      bitcoin/script.c
  5. 8
      bitcoin/signature.c
  6. 4
      bitcoin/tx.c
  7. 6
      find_p2sh_out.c
  8. 2
      permute_tx.c
  9. 6
      pkt.c
  10. 2
      protobuf_convert.c
  11. 2
      version.c

2
bitcoin/address.c

@ -1,6 +1,6 @@
#include <ccan/crypto/sha256/sha256.h>
#include "address.h" #include "address.h"
#include "pubkey.h" #include "pubkey.h"
#include <ccan/crypto/sha256/sha256.h>
void bitcoin_address(const struct pubkey *key, struct bitcoin_address *addr) void bitcoin_address(const struct pubkey *key, struct bitcoin_address *addr)
{ {

12
bitcoin/base58.c

@ -3,17 +3,17 @@
// Copyright (c) 2009-2012 The Bitcoin Developers // Copyright (c) 2009-2012 The Bitcoin Developers
// Distributed under the MIT/X11 software license, see the accompanying // Distributed under the MIT/X11 software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php. // file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include <ccan/build_assert/build_assert.h>
#include <ccan/tal/str/str.h>
#include <openssl/bn.h>
#include <assert.h>
#include <secp256k1.h>
#include <string.h>
#include "address.h" #include "address.h"
#include "base58.h" #include "base58.h"
#include "privkey.h" #include "privkey.h"
#include "pubkey.h" #include "pubkey.h"
#include "shadouble.h" #include "shadouble.h"
#include <assert.h>
#include <ccan/build_assert/build_assert.h>
#include <ccan/tal/str/str.h>
#include <openssl/bn.h>
#include <secp256k1.h>
#include <string.h>
static const char enc_16[] = "0123456789abcdef"; static const char enc_16[] = "0123456789abcdef";
static const char enc_58[] = static const char enc_58[] =

6
bitcoin/pubkey.c

@ -1,7 +1,7 @@
#include <ccan/str/hex/hex.h>
#include <assert.h>
#include "pubkey.h"
#include "privkey.h" #include "privkey.h"
#include "pubkey.h"
#include <assert.h>
#include <ccan/str/hex/hex.h>
/* Must agree on key validity with bitcoin! Stolen from bitcoin/src/pubkey.h's /* Must agree on key validity with bitcoin! Stolen from bitcoin/src/pubkey.h's
* GetLen: * GetLen:

8
bitcoin/script.c

@ -1,12 +1,12 @@
#include <ccan/crypto/ripemd160/ripemd160.h>
#include <ccan/crypto/sha256/sha256.h>
#include <ccan/endian/endian.h>
#include <assert.h>
#include "address.h" #include "address.h"
#include "locktime.h" #include "locktime.h"
#include "pubkey.h" #include "pubkey.h"
#include "script.h" #include "script.h"
#include "signature.h" #include "signature.h"
#include <assert.h>
#include <ccan/crypto/ripemd160/ripemd160.h>
#include <ccan/crypto/sha256/sha256.h>
#include <ccan/endian/endian.h>
/* Some standard ops */ /* Some standard ops */
#define OP_PUSHBYTES(val) (val) #define OP_PUSHBYTES(val) (val)

8
bitcoin/signature.c

@ -1,15 +1,15 @@
#include <ccan/cast/cast.h>
#include "privkey.h" #include "privkey.h"
#include "pubkey.h" #include "pubkey.h"
#include "script.h" #include "script.h"
#include "secp256k1.h" #include "secp256k1.h"
#ifdef USE_SCHNORR
#include "secp256k1_schnorr.h"
#endif
#include "shadouble.h" #include "shadouble.h"
#include "signature.h" #include "signature.h"
#include "tx.h" #include "tx.h"
#include <assert.h> #include <assert.h>
#ifdef USE_SCHNORR #include <ccan/cast/cast.h>
#include "secp256k1_schnorr.h"
#endif
#undef DEBUG #undef DEBUG
#ifdef DEBUG #ifdef DEBUG

4
bitcoin/tx.c

@ -1,3 +1,5 @@
#include "tx.h"
#include <assert.h>
#include <ccan/crypto/sha256/sha256.h> #include <ccan/crypto/sha256/sha256.h>
#include <ccan/endian/endian.h> #include <ccan/endian/endian.h>
#include <ccan/err/err.h> #include <ccan/err/err.h>
@ -5,8 +7,6 @@
#include <ccan/read_write_all/read_write_all.h> #include <ccan/read_write_all/read_write_all.h>
#include <ccan/str/hex/hex.h> #include <ccan/str/hex/hex.h>
#include <ccan/tal/grab_file/grab_file.h> #include <ccan/tal/grab_file/grab_file.h>
#include <assert.h>
#include "tx.h"
enum styles { enum styles {
/* Add the CT padding stuff to amount. */ /* Add the CT padding stuff to amount. */

6
find_p2sh_out.c

@ -1,9 +1,9 @@
#include <ccan/err/err.h>
#include <ccan/tal/tal.h>
#include <string.h>
#include "bitcoin/script.h" #include "bitcoin/script.h"
#include "bitcoin/tx.h" #include "bitcoin/tx.h"
#include "find_p2sh_out.h" #include "find_p2sh_out.h"
#include <ccan/err/err.h>
#include <ccan/tal/tal.h>
#include <string.h>
u32 find_p2sh_out(const struct bitcoin_tx *tx, u8 *redeemscript) u32 find_p2sh_out(const struct bitcoin_tx *tx, u8 *redeemscript)
{ {

2
permute_tx.c

@ -1,6 +1,6 @@
#include "permute_tx.h"
#include <stdbool.h> #include <stdbool.h>
#include <string.h> #include <string.h>
#include "permute_tx.h"
static void init_map(size_t *map, size_t len) static void init_map(size_t *map, size_t len)
{ {

6
pkt.c

@ -1,12 +1,12 @@
#include <ccan/crypto/sha256/sha256.h>
#include <ccan/err/err.h>
#include <ccan/tal/grab_file/grab_file.h>
#include "bitcoin/address.h" #include "bitcoin/address.h"
#include "bitcoin/pubkey.h" #include "bitcoin/pubkey.h"
#include "bitcoin/signature.h" #include "bitcoin/signature.h"
#include "bitcoin/tx.h" #include "bitcoin/tx.h"
#include "pkt.h" #include "pkt.h"
#include "protobuf_convert.h" #include "protobuf_convert.h"
#include <ccan/crypto/sha256/sha256.h>
#include <ccan/err/err.h>
#include <ccan/tal/grab_file/grab_file.h>
size_t pkt_totlen(const struct pkt *pkt) size_t pkt_totlen(const struct pkt *pkt)
{ {

2
protobuf_convert.c

@ -1,8 +1,8 @@
#include <ccan/crypto/sha256/sha256.h>
#include "bitcoin/locktime.h" #include "bitcoin/locktime.h"
#include "bitcoin/pubkey.h" #include "bitcoin/pubkey.h"
#include "bitcoin/signature.h" #include "bitcoin/signature.h"
#include "protobuf_convert.h" #include "protobuf_convert.h"
#include <ccan/crypto/sha256/sha256.h>
Signature *signature_to_proto(const tal_t *ctx, const struct signature *sig) Signature *signature_to_proto(const tal_t *ctx, const struct signature *sig)
{ {

2
version.c

@ -1,5 +1,5 @@
#include "version.h"
#include "gen_version.h" #include "gen_version.h"
#include "version.h"
#include <stdio.h> #include <stdio.h>
char *version_and_exit(const void *unused) char *version_and_exit(const void *unused)

Loading…
Cancel
Save