Wladimir J. van der Laan
cdcc319c2d
change type of various bare chars to bool that are only used as bool (and never serialized)
13 years ago
Wladimir J. van der Laan
7be8b2ff9c
Add explicit numeric constant value for all opcodes
...
- Easier for debugging (what opcode was 0x... again?)
- Clarifies that the opcodes are set in stone in the protocol, and signals that it is impossible to insert opcodes in between.
13 years ago
Wladimir J. van der Laan
00b9c0f4b2
Merge pull request #1122 from dlitz/unsigned-char-fix
...
Unsigned char fix & fix undefined phexdigits[255]
13 years ago
Pieter Wuille
3b9e6b7820
Merge pull request #959 from rebroad/LoadBlockIndexKillable
...
Added ability to respond to signals during Block Loading stage.
13 years ago
R E Broadley
871c3557bf
Added ability to respond to signals during Block Loading stage.
13 years ago
Dwayne C. Litzenberger
8c8e8c2e93
Fix bugs on 'unsigned char' platforms.
...
In ISO C++, the signedness of 'char' is undefined. On some platforms (e.g.
ARM), 'char' is an unsigned type, but some of the code relies on 'char' being
signed (as it is on x86). This is indicated by compiler warnings like this:
bignum.h: In constructor 'CBigNum::CBigNum(char)':
bignum.h:81:59: warning: comparison is always true due to limited range of data type [-Wtype-limits]
util.cpp: In function 'bool IsHex(const string&)':
util.cpp:427:28: warning: comparison is always false due to limited range of data type [-Wtype-limits]
In particular, IsHex erroneously returned true regardless of the input
characters, as long as the length of the string was a positive multiple of 2.
Note: For testing, it's possible using GCC to force char to be unsigned by
adding the -funsigned-char parameter to xCXXFLAGS.
13 years ago
Dwayne C. Litzenberger
a6fa147c8d
Fix phexdigits[255] is undefined.
13 years ago
Wladimir J. van der Laan
ac4161e25d
Merge pull request #1118 from sipa/addbreaks
...
Add missing breaks in optionmodel's switch case
13 years ago
Pieter Wuille
559fc3c610
Add missing breaks in optionmodel's switch case
13 years ago
Pieter Wuille
031eae7864
Merge pull request #1114 from sipa/lesssync
...
Reduce sync frequency for blkindex.dat
13 years ago
Pieter Wuille
0a83c0fcef
Fix tests after recent refactors
13 years ago
Pieter Wuille
c23617fef3
Merge remote-tracking branch 'jgarzik/mempool'
13 years ago
Pieter Wuille
caeddc5d37
Merge pull request #1117 from sipa/deadlockfix
...
Fix potential deadlock
13 years ago
Pieter Wuille
1ffeb89a52
Merge pull request #1112 from sipa/saneserial
...
Further reduce header dependencies
13 years ago
Pieter Wuille
6b6aaa1698
Further reduce header dependencies
...
This commit removes the dependency of serialize.h on PROTOCOL_VERSION,
and makes this parameter required instead of implicit. This is much saner,
as it makes the places where changing a version number can have an
influence obvious.
13 years ago
Jeff Garzik
ccd65d4261
Move proto version to version.h. Reduce header deps a bit more.
13 years ago
Jeff Garzik
9eace6b113
Move CWalletDB code to new walletdb module.
...
In addition to standard code separation, this change opens the door
to fixing several include inter-dependencies.
13 years ago
Pieter Wuille
ed6d0b5f85
Remove headers.h
13 years ago
Gavin Andresen
b97d54355e
Merge pull request #1106 from jgarzik/sign-compare
...
Fix many sign-comparison warnings found in bitcoin codebase
13 years ago
Gavin Andresen
e873dc654c
Merge pull request #1115 from laanwj/2012_04_cleanupmisc
...
Delete unused, unreachable and commented code, add missing initializer
13 years ago
Pieter Wuille
c581cc16bb
Fix potential deadlock
...
Conflict:
* cs_main in ProcessMessages() (before calling ProcessMessages)
* cs_vSend in CNode::BeginMessage
versus:
* cs_vSend in ThreadMessageHandler2 (before calling SendMessages)
* cs_main in SendMessages
Even though cs_vSend is a try_lock, if it succeeds simultaneously with
the locking of cs_main in ProcessMessages(), it could cause a deadlock.
13 years ago
Jeff Garzik
ce8c93498a
main.cpp: replace tabs with spaces
...
Sometimes they sneak in through the 'vi' door
13 years ago
Jeff Garzik
8bff8ac079
AlreadyHave(): only hold lock during mapTransactions access
13 years ago
Wladimir J. van der Laan
7fa3ad83a9
Remove unused and unreachable code
13 years ago
Wladimir J. van der Laan
4941aad657
Add forgotten initializer
13 years ago
Pieter Wuille
8f2b50f178
Reduce sync frequency for blkindex.dat
...
Since auto-remove-db-logs was enabled, each time a CTxDB was closed
outside of the initial download window, it causes a checkpoint + log
cleanup. This is overkill, so reduce the sync frequency to once per
minute at most.
13 years ago
Jeff Garzik
dd21ce5f1b
Merge pull request #1094 from jgarzik/already-have-locking
...
Locking fix for AlreadyHave()
13 years ago
Jeff Garzik
ea9627979e
Bump PROTOCOL_VERSION to 60001, thereby enabling BIP31
13 years ago
Jeff Garzik
865a0c1674
Merge pull request #1081 from jgarzik/pong
...
BIP 0031: pong message
13 years ago
Wladimir J. van der Laan
7a5452ffb3
Merge pull request #1092 from laanwj/2012_04_sendcoins_setlabelfix
...
When sending coins, set label when selecting address that already has a label
13 years ago
Wladimir J. van der Laan
088a13331b
Merge pull request #1091 from Diapolo/GUI-BlockDL
...
revert to default OS theme for progressbar (fix #1071 )
13 years ago
Jeff Garzik
9fb89c26f3
Fix misc. minor sign-comparison warnings
13 years ago
Jeff Garzik
0dd710acb6
CNode's nHeaderStart may be negative, so change its type
13 years ago
Jeff Garzik
c3fad8350b
serialize.h: CAutoFile's read and write may take size_t nSize
13 years ago
Jeff Garzik
3a78f82a78
Fix sign-compare warnings: netbase's Lookup* max-solutions may be unsigned
13 years ago
Jeff Garzik
c376ac359e
Fix loop index var types, fixing many minor sign comparison warnings
...
foo.size() typically returns an unsigned integral type; make loop variables
match those types' signedness.
13 years ago
Jeff Garzik
ab9dc75a18
The string class returns string::npos, when find() fails.
...
Noticed when sign-comparison warnings were enabled.
13 years ago
Jeff Garzik
ca4c4c53a8
CTxMemPool: add helper methods, to reduce global mempool.mapTx accesses
13 years ago
Jeff Garzik
d01903e751
CTxMemPool: encapsulate AcceptToMemoryPool
13 years ago
Jeff Garzik
8e45ed66dd
CTxMemPool: encapsulate AddToMemoryPoolUnchecked(), RemoveFromMemoryPool(),
...
and nPooledTx
13 years ago
Jeff Garzik
235507ae48
New class CTxMemPool, encapsulating TX memory pool data members
13 years ago
Jeff Garzik
5a701eb7ea
Merge pull request #1104 from laanwj/2012_04_clang
...
Enable and fix most compilation warnings
13 years ago
Jeff Garzik
fced2231f8
Merge pull request #1084 from dooglus/validate_secret
...
importprivkey doesn't check that it is given a private key
13 years ago
Wladimir J. van der Laan
9ea8e60a0c
Merge pull request #1097 from laanwj/2012_04_runawayexception
...
Show a message box when runaway exception happens
13 years ago
Jeff Garzik
c99ddfaa22
Merge pull request #1100 from luke-jr/qrcode_errchk
...
Bugfix: Check that QRcode_encodeString didn't return NULL (error)
13 years ago
Wladimir J. van der Laan
da7bbd9dfd
fix warnings: suggest explicit braces to avoid ambiguous 'else' [-Wparentheses]
13 years ago
Wladimir J. van der Laan
6642ffb761
fix warnings: '&&' within '||' [-Wlogical-op-parentheses]
13 years ago
Wladimir J. van der Laan
2e120f28e0
fix warnings: delete called on 'XX' that has virtual functions but non-virtual destructor [-Wdelete-non-virtual-dtor]
13 years ago
Wladimir J. van der Laan
11cd416525
fix warnings: unused variable 'XX' [-Wunused-variable]
13 years ago
Wladimir J. van der Laan
76d8170ce8
fix warnings: enumeration values 'XX' not handled in switch [-Wswitch-enum]
13 years ago