Fix typos

This commit is contained in:
practicalswift 2017-12-07 23:59:39 +01:00 committed by Christian Decker
parent 5444084625
commit 61c47c09d0
17 changed files with 25 additions and 25 deletions

View File

@ -192,7 +192,7 @@ check-hdr-include-order/%: %
check-makefile:
@if [ x"$(CCANDIR)/config.h `find $(CCANDIR)/ccan -name '*.h' | grep -v /test/ | LC_ALL=C sort | tr '\n' ' '`" != x"$(CCAN_HEADERS) " ]; then echo CCAN_HEADERS incorrect; exit 1; fi
# Any mention of BOLT# must be followed by an exact quote, modulo whitepace.
# Any mention of BOLT# must be followed by an exact quote, modulo whitespace.
bolt-check/%: % bolt-precheck tools/check-bolt
@[ ! -d .tmp.lightningrfc ] || tools/check-bolt .tmp.lightningrfc $<

View File

@ -101,7 +101,7 @@ This returns a random value called `rhash` that is part of the invoice.
The recipient needs to communicate its ID `<recipient_id>`, `<rhash>` and the desired `<amount>` to the sender.
The sender needs to compute a route to the recipient, and use that route to actually send the payment.
The route contains the path that the payment will take throught the Lightning Network and the respective funds that each node will forward.
The route contains the path that the payment will take through the Lightning Network and the respective funds that each node will forward.
```
route=$(cli/lightning-cli getroute <recipient_id> <amount> 1 | jq --raw-output .route -)

View File

@ -899,7 +899,7 @@ static bool adjust_balance(struct channel *channel, struct htlc *htlc)
if (!htlc->fail && !htlc->malformed && !htlc->r) {
status_trace("%s HTLC %"PRIu64
" %s neither fail nor fulfull?",
" %s neither fail nor fulfill?",
htlc_state_owner(htlc->state) == LOCAL
? "out" : "in",
htlc->id,

View File

@ -97,7 +97,7 @@ int bech32_encode(
* of entries in data.
* In: input: Pointer to a null-terminated Bech32 string.
* max_input_len: Maximum valid length of input (90 for segwit usage).
* Returns 1 if succesful.
* Returns 1 if successful.
*/
int bech32_decode(
char *hrp,

View File

@ -310,7 +310,7 @@ again:
/* Cut to length and return. */
*valid = true;
tal_resize(&toks, ret + 1);
/* Make sure last one is always referencable. */
/* Make sure last one is always referenceable. */
toks[ret].type = -1;
toks[ret].start = toks[ret].end = toks[ret].size = 0;

View File

@ -91,7 +91,7 @@ static bool output_better(const struct bitcoin_tx_output *a,
if (a->amount != b->amount)
return a->amount < b->amount;
/* Lexographic sort. */
/* Lexicographical sort. */
if (tal_len(a->script) < tal_len(b->script))
len = tal_len(a->script);
else

View File

@ -19,7 +19,7 @@ struct utxo;
* @destination: (in) bitcoin_address to send to.
* @amount: (in) satoshis to send to the destination
* @changekey: (in) key to send change to (only used if change_satoshis != 0).
* @changesa: (in) amount to send as change.
* @changesat: (in) amount to send as change.
* @bip32_base: (in) bip32 base for key derivation, or NULL.
*/
struct bitcoin_tx *withdraw_tx(const tal_t *ctx,

View File

@ -14,7 +14,7 @@ It's in C, to encourage alternate implementations. It uses the Linux
coding style. Patches are welcome!
To read the code, you'll probably need to understand ccan/tal: it's a
heirarchical memory allocator, where each allocation has a parent, and
hierarchical memory allocator, where each allocation has a parent, and
thus lifetimes are grouped. eg. a 'struct bitcoin_tx' has a pointer
to an array of 'struct bitcoin_tx_input'; they are allocated off the
'struct bitcoind_tx', so freeing the 'struct bitcoind_tx' frees them
@ -34,7 +34,7 @@ Here's a list of parts, with notes:
* bitcoin/ - bitcoin script, signature and transaction routines.
- Not a complete set, but enough for our purposes.
* external/ - external libararies from other sources
* external/ - external libraries from other sources
- libsodium - encryption library (should be replaced soon with built-in)
- libwally-core - bitcoin helper library
- secp256k1 - bitcoin curve encryption library within libwally-core

View File

@ -384,7 +384,7 @@ find_route(const tal_t *ctx, struct routing_state *rstate,
msatoshi += *fee;
status_trace("find_route: via %s",
type_to_string(trc, struct pubkey, &first_conn->dst->id));
/* If there are intermidiaries, dump them, and total fees. */
/* If there are intermediaries, dump them, and total fees. */
if (best != 0) {
for (i = 0; i < best; i++) {
status_trace(" %s (%i+%i=%"PRIu64")",
@ -700,7 +700,7 @@ void handle_node_announcement(
node = get_node(rstate, &node_id);
if (!node) {
status_trace("Node not found, was the node_announcement preceeded by at least channel_announcement?");
status_trace("Node not found, was the node_announcement preceded by at least channel_announcement?");
tal_free(tmpctx);
return;
} else if (node->last_timestamp >= timestamp) {

View File

@ -107,10 +107,10 @@ struct chain_topology {
/* Our timer list. */
struct timers *timers;
/* Bitcoin transctions we're broadcasting */
/* Bitcoin transactions we're broadcasting */
struct list_head outgoing_txs;
/* Force a partiular fee rate regardless of estimatefee (satoshis/kb) */
/* Force a particular fee rate regardless of estimatefee (satoshis/kb) */
u32 *override_fee_rate;
/* What fee we use if estimatefee fails (satoshis/kb) */

View File

@ -471,7 +471,7 @@ static void parse_request(struct json_connection *jcon, const jsmntok_t tok[])
return;
}
/* This is a convenient tal parent for durarion of command
/* This is a convenient tal parent for duration of command
* (which may outlive the conn!). */
jcon->current = tal(jcon->ld, struct command);
jcon->current->jcon = jcon;

View File

@ -448,7 +448,7 @@ static void log_crash(int sig)
logfile = "crash.log";
fd = open(logfile, O_WRONLY|O_CREAT, 0600);
if (fd < 0) {
logfile = "/tmp/lighning-crash.log";
logfile = "/tmp/lightning-crash.log";
fd = open(logfile, O_WRONLY|O_CREAT, 0600);
}

View File

@ -1040,7 +1040,7 @@ static void onchaind_tell_fulfill(struct peer *peer)
/* We only set preimage once it's irrevocably committed, and
* we spend even if we don't have an outgoing HTLC (eg. local
* payyment complete) */
* payment complete) */
if (!hin->preimage)
continue;
@ -2226,7 +2226,7 @@ static void opening_funder_finished(struct subd *opening, const u8 *resp,
/* old_remote_per_commit not valid yet, copy valid one. */
channel_info->old_remote_per_commit = channel_info->remote_per_commit;
/* Now, keep the initial commit as our last-tx-to-broadast. */
/* Now, keep the initial commit as our last-tx-to-broadcast. */
peer_last_tx(fc->peer, remote_commit, &remote_commit_sig);
/* Generate the funding tx. */
@ -2350,7 +2350,7 @@ static void opening_fundee_finished(struct subd *opening,
/* old_remote_per_commit not valid yet, copy valid one. */
channel_info->old_remote_per_commit = channel_info->remote_per_commit;
/* Now, keep the initial commit as our last-tx-to-broadast. */
/* Now, keep the initial commit as our last-tx-to-broadcast. */
peer_last_tx(peer, remote_commit, &remote_commit_sig);
if (!peer_commit_initial(peer))

View File

@ -1497,7 +1497,7 @@ static void handle_their_cheat(const struct bitcoin_tx *tx,
sizeof(per_commitment_privkey));
if (!pubkey_from_privkey(&per_commitment_privkey, &per_commitment_point))
status_failed(STATUS_FAIL_INTERNAL_ERROR,
"Failed derivea from per_commitment_secret %s",
"Failed derive from per_commitment_secret %s",
type_to_string(trc, struct privkey,
&per_commitment_privkey));
@ -2061,7 +2061,7 @@ int main(int argc, char *argv[])
&remote_payment_basepoint);
status_trace("commitnum = %"PRIu64
", revocations_recived = %"PRIu64,
", revocations_received = %"PRIu64,
commit_num, revocations_received(&shachain));
if (is_local_commitment(&txid, &our_broadcast_txid))

View File

@ -250,7 +250,7 @@ class LightningDTests(BaseLightningDTests):
if out['scriptPubKey']['type'] == 'witness_v0_scripthash':
if out['value'] == Decimal(amount) / 10**8 or out['value'] * 10**8 == amount:
return "{}:1:{}".format(bitcoind.rpc.getblockcount(), out['n'])
# Intermittant decoding failure. See if it decodes badly twice?
# Intermittent decoding failure. See if it decodes badly twice?
decoded2=bitcoind.rpc.decoderawtransaction(tx)
raise ValueError("Can't find {} payment in {} (1={} 2={})".format(amount, tx, decoded, decoded2))
@ -1003,7 +1003,7 @@ class LightningDTests(BaseLightningDTests):
l2.daemon.wait_for_log('Broadcasting OUR_DELAYED_RETURN_TO_WALLET .* to resolve OUR_UNILATERAL/DELAYED_OUTPUT_TO_US')
l2.daemon.wait_for_log('sendrawtx exit 0')
# One more block, HTLC tx is now spentable.
# One more block, HTLC tx is now spendable.
l1.bitcoin.generate_block(1)
l2.daemon.wait_for_log('Broadcasting OUR_DELAYED_RETURN_TO_WALLET .* to resolve OUR_HTLC_SUCCESS_TX/DELAYED_OUTPUT_TO_US')
l2.daemon.wait_for_log('sendrawtx exit 0')

View File

@ -49,7 +49,7 @@ class FieldType(object):
if typename in type2size:
return type2size[typename]
elif typename.startswith('struct ') or typename.startswith('enum '):
# We allow unknown structures/enums, for extensiblity (can only happen
# We allow unknown structures/enums, for extensibility (can only happen
# if explicitly specified in csv)
return 0
else:

View File

@ -254,7 +254,7 @@ static struct db *db_open(const tal_t *ctx, char *filename)
sqlite3 *sql;
if (SQLITE_VERSION_NUMBER != sqlite3_libversion_number())
fatal("SQLITE version mistmatch: compiled %u, now %u",
fatal("SQLITE version mismatch: compiled %u, now %u",
SQLITE_VERSION_NUMBER, sqlite3_libversion_number());
int flags = SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE;
@ -305,7 +305,7 @@ static int db_get_version(struct db *db)
}
/**
* db_mirgation_count - Count how many migrations are available
* db_migration_count - Count how many migrations are available
*
* Returns the maximum migration index, i.e., the version number of an
* up-to-date database schema.