qt: restore icon dock menu

This was removed by 25c0cce7f. It was apparently removed in qt5, but
may return for 5.1.
Refactor: pull alert string sanitization into util

Rebased-from: 17faf562629cd27f00fc138e218ebcc1ce071765
Store and use a sanitized subVer

Rebased-from: a946aa8d3ec7009ac670eeb65a525efe5eeb6e84
Bugfix: Move boost/version include from db.cpp to walletdb.cpp where BOOST_VERSION is used
fix invalid conversion error with MinGW 4.8.1 in net.cpp

- fixes src\net.cpp:1601: Error:invalid conversion from 'void*' to
  'const char*' [-fpermissive] in a setsockopt() call on Win32 that was
  found by using MinGW 4.8.1 compiler suite
Make the rand tests determinstic. (fixes #2714)

This avoids spurious errors with the old tests but still tests
 enough that if the rng is replaced with a totally broken one
 it should still fail.
Create parent directories if needed in GetDataDir

One-line change. Fixes #2752.
Fix typo in a comment: it's base58, not base48.
Bitcoin-Qt: Fix display of window when bitcoin: URI is opened

WalletView:
- add new signal showNormalIfMinimized()
- emit the new signal in handleURI() to fix a bug, preventing the main
  window to show up when using bitcoin: URIs

Upstream: dbc0a6aba2cf94aa1b167145a18e0b9c671aef5b
qt: use deleteLater to remove send entries

Use deleteLater() instead of delete, as it is not allowed
to delete widgets directly in an event handler.
Should solve the MacOSX random crashes on send with coincontrol.

Rebased-From: 6c98cca9e47ddb9c786cd3f0445175c378515e0d
Refuse to retransmit transactions without vins

Versions of bitcoin before 0.8.6 have a bug that inserted
empty transactions into the vtxPrev in the wallet, which will cause the node to be
banned when retransmitted, hence add a check for !tx.vin.empty()
before RelayTransaction.
Prevent empty transactions from being added to vtxPrev

CWalletTx::AddSupportingTransactions() was adding empty transaction
to vtxPrev in some cases. Skip over these.

Part one of the solution to #3190. This prevents invalid vtxPrev from
entering the wallet, but not current ones being transmitted.
leveldb: Use native Darwin memory barriers
dont use mmap in leveldb, this is a marginal performance hit

fail on short writes

Ensure new files referred to by the manifest are in the filesystem.
LevelDB: use PosixWriteableFile only on MacOS X

mmap is proven on the other platforms, we are not changing it at
the last moment before release.
Litecoin: Checkpoint at block 456000
Litecoin: Reduce prioritysize from 27KB to 17KB
Litecoin: Reduce high priority tx size limit to 5KB (from 10KB)

This is the first step in making the high priority transaction area
available to more people.  Future versions of Litecoin will eventually
reduce this to 1KB per tx to match Bitcoin 0.8.6+.  We decline to
make that drastic of a reduction now as currently p2pool miners have
too much dust to combine.

Litecoin plays an active role in p2pool development to make this less
of a problem.  Litecoin helped p2pool version 13 to reduce the
frequency of dust payouts and increase the smallest dust size to be
roughly 5x bigger.  An upcoming version of p2pool is expected to
eliminate a lot more dust payouts.

Modified-from: 9612e4c0d9730dbdb9971e53c72df17dd97daa2a
Litecoin: Reduce Dust thresholds by 10x

DUST_SOFT_LIMIT of 0.001 means a penalty of an additional mintxfee
is charged for each output smaller than 0.001.  This is a key
behavioral disincentive in Litecoin's anti-spam design.

DUST_HARD_LIMIT of 0.00001 means inputs smaller than this size are
ignored by the wallet, not available to coin selection and
effectively do not exist.  This too discourages spam.
Litecoin: Update pnSeed array