From 880c47863587ef4f464c4d681713e1f24cbf1cb7 Mon Sep 17 00:00:00 2001 From: Pieter Wuille Date: Mon, 9 Jan 2012 23:39:26 +0100 Subject: [PATCH 1/3] Remove unused definition --- src/wallet.h | 1 - 1 file changed, 1 deletion(-) diff --git a/src/wallet.h b/src/wallet.h index 794139233d0..3560a725801 100644 --- a/src/wallet.h +++ b/src/wallet.h @@ -77,7 +77,6 @@ public: bool CreateTransaction(const std::vector >& vecSend, CWalletTx& wtxNew, CReserveKey& reservekey, int64& nFeeRet); bool CreateTransaction(CScript scriptPubKey, int64 nValue, CWalletTx& wtxNew, CReserveKey& reservekey, int64& nFeeRet); bool CommitTransaction(CWalletTx& wtxNew, CReserveKey& reservekey); - bool BroadcastTransaction(CWalletTx& wtxNew); std::string SendMoney(CScript scriptPubKey, int64 nValue, CWalletTx& wtxNew, bool fAskFee=false); std::string SendMoneyToBitcoinAddress(const CBitcoinAddress& address, int64 nValue, CWalletTx& wtxNew, bool fAskFee=false); From 948072c39f913d1ebe43b3b46234f9d7a0d00427 Mon Sep 17 00:00:00 2001 From: Luke Dashjr Date: Mon, 16 Jan 2012 22:17:48 -0500 Subject: [PATCH 2/3] Code tidyups, fixing various warnings. Partial cherry pick of: Compile with extra warnings turned on. And more makefile/code tidying up. This turns on most gcc warnings, and removes some unused variables and other code that triggers warnings. Exceptions are: -Wno-sign-compare : triggered by lots of comparisons of signed integer to foo.size(), which is unsigned. -Wno-char-subscripts : triggered by the convert-to-hex functions (I may fix this in a future commit). Conflicts: src/makefile.osx src/makefile.unix src/netbase.cpp src/rpc.cpp --- src/checkpoints.cpp | 1 - src/headers.h | 2 -- src/net.cpp | 3 --- src/net.h | 4 +++- src/serialize.h | 3 +++ 5 files changed, 6 insertions(+), 7 deletions(-) diff --git a/src/checkpoints.cpp b/src/checkpoints.cpp index c7e054df378..508f72b3765 100644 --- a/src/checkpoints.cpp +++ b/src/checkpoints.cpp @@ -52,7 +52,6 @@ namespace Checkpoints { if (fTestNet) return NULL; - int64 nResult; BOOST_REVERSE_FOREACH(const MapCheckpoints::value_type& i, mapCheckpoints) { const uint256& hash = i.second; diff --git a/src/headers.h b/src/headers.h index ab318cbb436..96db87db1ba 100644 --- a/src/headers.h +++ b/src/headers.h @@ -91,8 +91,6 @@ #endif -#pragma hdrstop - #include "serialize.h" #include "uint256.h" #include "util.h" diff --git a/src/net.cpp b/src/net.cpp index c7475b118cf..e3c0f8c3d18 100644 --- a/src/net.cpp +++ b/src/net.cpp @@ -1082,7 +1082,6 @@ void ThreadMapPort2(void* parg) char port[6]; sprintf(port, "%d", GetListenPort()); - const char * rootdescurl = 0; const char * multicastif = 0; const char * minissdpdpath = 0; struct UPNPDev * devlist = 0; @@ -1104,8 +1103,6 @@ void ThreadMapPort2(void* parg) r = UPNP_GetValidIGD(devlist, &urls, &data, lanaddr, sizeof(lanaddr)); if (r == 1) { - char intClient[16]; - char intPort[6]; string strDesc = "Bitcoin " + FormatFullVersion(); #ifndef UPNPDISCOVER_SUCCESS /* miniupnpc 1.5 */ diff --git a/src/net.h b/src/net.h index 741e2a812ec..03d514ca909 100644 --- a/src/net.h +++ b/src/net.h @@ -264,7 +264,9 @@ public: // Make sure not to reuse time indexes to keep things in the same order int64 nNow = (GetTime() - 1) * 1000000; static int64 nLastTime; - nLastTime = nNow = std::max(nNow, ++nLastTime); + ++nLastTime; + nNow = std::max(nNow, nLastTime); + nLastTime = nNow; // Each retry is 2 minutes after the last nRequestTime = std::max(nRequestTime + 2 * 60 * 1000000, nNow); diff --git a/src/serialize.h b/src/serialize.h index d7b5ec80d56..385c9ab8e93 100644 --- a/src/serialize.h +++ b/src/serialize.h @@ -98,6 +98,7 @@ enum const bool fRead = false; \ unsigned int nSerSize = 0; \ ser_streamplaceholder s; \ + assert(fGetSize||fWrite||fRead); /* suppress warning */ \ s.nType = nType; \ s.nVersion = nVersion; \ {statements} \ @@ -111,6 +112,7 @@ enum const bool fWrite = true; \ const bool fRead = false; \ unsigned int nSerSize = 0; \ + assert(fGetSize||fWrite||fRead); /* suppress warning */ \ {statements} \ } \ template \ @@ -121,6 +123,7 @@ enum const bool fWrite = false; \ const bool fRead = true; \ unsigned int nSerSize = 0; \ + assert(fGetSize||fWrite||fRead); /* suppress warning */ \ {statements} \ } From 5df96269d30ec57e69676e6937b45b3608df98ac Mon Sep 17 00:00:00 2001 From: Janne Pulkkinen Date: Sat, 14 Jan 2012 21:31:49 +0200 Subject: [PATCH 3/3] *Clear all has a tooltip now *About dialog updated --- src/qt/forms/aboutdialog.ui | 2 +- src/qt/forms/sendcoinsdialog.ui | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/qt/forms/aboutdialog.ui b/src/qt/forms/aboutdialog.ui index cf7997326cc..127b90965a6 100644 --- a/src/qt/forms/aboutdialog.ui +++ b/src/qt/forms/aboutdialog.ui @@ -82,7 +82,7 @@ - Copyright © 2009-2011 Bitcoin Developers + Copyright © 2009-2012 Bitcoin Developers This is experimental software. diff --git a/src/qt/forms/sendcoinsdialog.ui b/src/qt/forms/sendcoinsdialog.ui index e5e19e10158..04cf404ae3c 100644 --- a/src/qt/forms/sendcoinsdialog.ui +++ b/src/qt/forms/sendcoinsdialog.ui @@ -80,6 +80,9 @@ 0 + + Remove all transaction fields + Clear all