diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/core.cpp | 29 | ||||
-rw-r--r-- | src/core.h | 1 | ||||
-rw-r--r-- | src/key.cpp | 15 | ||||
-rw-r--r-- | src/key.h | 4 | ||||
-rw-r--r-- | src/main.cpp | 18 | ||||
-rw-r--r-- | src/main.h | 3 | ||||
-rw-r--r-- | src/net.cpp | 27 | ||||
-rw-r--r-- | src/net.h | 1 | ||||
-rw-r--r-- | src/netbase.cpp | 46 | ||||
-rw-r--r-- | src/netbase.h | 3 | ||||
-rw-r--r-- | src/qt/guiutil.cpp | 4 | ||||
-rw-r--r-- | src/qt/locale/bitcoin_da.ts | 166 | ||||
-rw-r--r-- | src/qt/locale/bitcoin_id_ID.ts | 72 | ||||
-rw-r--r-- | src/qt/locale/bitcoin_ko_KR.ts | 74 | ||||
-rw-r--r-- | src/qt/locale/bitcoin_ro_RO.ts | 6 | ||||
-rw-r--r-- | src/qt/notificator.cpp | 2 | ||||
-rw-r--r-- | src/qt/test/test_main.cpp | 1 | ||||
-rw-r--r-- | src/rpcnet.cpp | 2 | ||||
-rw-r--r-- | src/rpcprotocol.cpp | 10 | ||||
-rw-r--r-- | src/test/util_tests.cpp | 4 | ||||
-rw-r--r-- | src/util.cpp | 18 | ||||
-rw-r--r-- | src/util.h | 11 | ||||
-rw-r--r-- | src/wallet.cpp | 15 | ||||
-rw-r--r-- | src/wallet.h | 1 |
24 files changed, 237 insertions, 296 deletions
diff --git a/src/core.cpp b/src/core.cpp index 7651ce9957..aadcb44b98 100644 --- a/src/core.cpp +++ b/src/core.cpp @@ -77,35 +77,6 @@ uint256 CTransaction::GetHash() const return SerializeHash(*this); } -bool CTransaction::IsNewerThan(const CTransaction& old) const -{ - if (vin.size() != old.vin.size()) - return false; - for (unsigned int i = 0; i < vin.size(); i++) - if (vin[i].prevout != old.vin[i].prevout) - return false; - - bool fNewer = false; - unsigned int nLowest = std::numeric_limits<unsigned int>::max(); - for (unsigned int i = 0; i < vin.size(); i++) - { - if (vin[i].nSequence != old.vin[i].nSequence) - { - if (vin[i].nSequence <= nLowest) - { - fNewer = false; - nLowest = vin[i].nSequence; - } - if (old.vin[i].nSequence < nLowest) - { - fNewer = true; - nLowest = old.vin[i].nSequence; - } - } - } - return fNewer; -} - int64_t CTransaction::GetValueOut() const { int64_t nValueOut = 0; diff --git a/src/core.h b/src/core.h index 5eb953610d..ba7f691119 100644 --- a/src/core.h +++ b/src/core.h @@ -219,7 +219,6 @@ public: } uint256 GetHash() const; - bool IsNewerThan(const CTransaction& old) const; // Return sum of txouts. int64_t GetValueOut() const; diff --git a/src/key.cpp b/src/key.cpp index 2199996cf3..aa24f0a622 100644 --- a/src/key.cpp +++ b/src/key.cpp @@ -485,21 +485,6 @@ bool CPubKey::RecoverCompact(const uint256 &hash, const std::vector<unsigned cha return true; } -bool CPubKey::VerifyCompact(const uint256 &hash, const std::vector<unsigned char>& vchSig) const { - if (!IsValid()) - return false; - if (vchSig.size() != 65) - return false; - CECKey key; - if (!key.Recover(hash, &vchSig[1], (vchSig[0] - 27) & ~4)) - return false; - CPubKey pubkeyRec; - key.GetPubKey(pubkeyRec, IsCompressed()); - if (*this != pubkeyRec) - return false; - return true; -} - bool CPubKey::IsFullyValid() const { if (!IsValid()) return false; @@ -156,10 +156,6 @@ public: // If this public key is not fully valid, the return value will be false. bool Verify(const uint256 &hash, const std::vector<unsigned char>& vchSig) const; - // Verify a compact signature (~65 bytes). - // See CKey::SignCompact. - bool VerifyCompact(const uint256 &hash, const std::vector<unsigned char>& vchSig) const; - // Recover a public key from a compact signature. bool RecoverCompact(const uint256 &hash, const std::vector<unsigned char>& vchSig); diff --git a/src/main.cpp b/src/main.cpp index c54fa65233..18c00d90ac 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -2575,19 +2575,6 @@ bool CBlockIndex::IsSuperMajority(int minVersion, const CBlockIndex* pstart, uns return (nFound >= nRequired); } -int64_t CBlockIndex::GetMedianTime() const -{ - AssertLockHeld(cs_main); - const CBlockIndex* pindex = this; - for (int i = 0; i < nMedianTimeSpan/2; i++) - { - if (!chainActive.Next(pindex)) - return GetBlockTime(); - pindex = chainActive.Next(pindex); - } - return pindex->GetMedianTimePast(); -} - void PushGetBlocks(CNode* pnode, CBlockIndex* pindexBegin, uint256 hashEnd) { AssertLockHeld(cs_main); @@ -3488,7 +3475,10 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv) return true; } - State(pfrom->GetId())->nLastBlockProcess = GetTimeMicros(); + { + LOCK(cs_main); + State(pfrom->GetId())->nLastBlockProcess = GetTimeMicros(); + } diff --git a/src/main.h b/src/main.h index 1dc48c0af8..8a05eb60d2 100644 --- a/src/main.h +++ b/src/main.h @@ -102,7 +102,6 @@ extern unsigned int nCoinCacheSize; static const uint64_t nMinDiskSpace = 52428800; -class CCoinsDB; class CBlockTreeDB; struct CDiskBlockPos; class CTxUndo; @@ -849,8 +848,6 @@ public: return pbegin[(pend - pbegin)/2]; } - int64_t GetMedianTime() const; - /** * Returns true if there are nRequired or more blocks of minVersion or above * in the last nToCheck blocks, starting at pstart and going backwards. diff --git a/src/net.cpp b/src/net.cpp index 6bde1e7999..319f8e6b1c 100644 --- a/src/net.cpp +++ b/src/net.cpp @@ -41,9 +41,6 @@ using namespace boost; static const int MAX_OUTBOUND_CONNECTIONS = 8; -bool OpenNetworkConnection(const CAddress& addrConnect, CSemaphoreGrant *grantOutbound = NULL, const char *strDest = NULL, bool fOneShot = false); - - // // Global state variables // @@ -178,7 +175,7 @@ bool RecvLine(SOCKET hSocket, string& strLine) { // socket error int nErr = WSAGetLastError(); - LogPrint("net", "recv failed: %d\n", nErr); + LogPrint("net", "recv failed: %s\n", NetworkErrorString(nErr)); return false; } } @@ -489,10 +486,10 @@ CNode* ConnectNode(CAddress addrConnect, const char *pszDest) #ifdef WIN32 u_long nOne = 1; if (ioctlsocket(hSocket, FIONBIO, &nOne) == SOCKET_ERROR) - LogPrintf("ConnectSocket() : ioctlsocket non-blocking setting failed, error %d\n", WSAGetLastError()); + LogPrintf("ConnectSocket() : ioctlsocket non-blocking setting failed, error %s\n", NetworkErrorString(WSAGetLastError())); #else if (fcntl(hSocket, F_SETFL, O_NONBLOCK) == SOCKET_ERROR) - LogPrintf("ConnectSocket() : fcntl non-blocking setting failed, error %d\n", errno); + LogPrintf("ConnectSocket() : fcntl non-blocking setting failed, error %s\n", NetworkErrorString(errno)); #endif // Add node @@ -736,7 +733,7 @@ void SocketSendData(CNode *pnode) int nErr = WSAGetLastError(); if (nErr != WSAEWOULDBLOCK && nErr != WSAEMSGSIZE && nErr != WSAEINTR && nErr != WSAEINPROGRESS) { - LogPrintf("socket send error %d\n", nErr); + LogPrintf("socket send error %s\n", NetworkErrorString(nErr)); pnode->CloseSocketDisconnect(); } } @@ -896,7 +893,7 @@ void ThreadSocketHandler() if (have_fds) { int nErr = WSAGetLastError(); - LogPrintf("socket select error %d\n", nErr); + LogPrintf("socket select error %s\n", NetworkErrorString(nErr)); for (unsigned int i = 0; i <= hSocketMax; i++) FD_SET(i, &fdsetRecv); } @@ -933,7 +930,7 @@ void ThreadSocketHandler() { int nErr = WSAGetLastError(); if (nErr != WSAEWOULDBLOCK) - LogPrintf("socket error accept failed: %d\n", nErr); + LogPrintf("socket error accept failed: %s\n", NetworkErrorString(nErr)); } else if (nInbound >= nMaxConnections - MAX_OUTBOUND_CONNECTIONS) { @@ -1007,7 +1004,7 @@ void ThreadSocketHandler() if (nErr != WSAEWOULDBLOCK && nErr != WSAEMSGSIZE && nErr != WSAEINTR && nErr != WSAEINPROGRESS) { if (!pnode->fDisconnect) - LogPrintf("socket recv error %d\n", nErr); + LogPrintf("socket recv error %s\n", NetworkErrorString(nErr)); pnode->CloseSocketDisconnect(); } } @@ -1585,7 +1582,7 @@ bool BindListenPort(const CService &addrBind, string& strError) SOCKET hListenSocket = socket(((struct sockaddr*)&sockaddr)->sa_family, SOCK_STREAM, IPPROTO_TCP); if (hListenSocket == INVALID_SOCKET) { - strError = strprintf("Error: Couldn't open socket for incoming connections (socket returned error %d)", WSAGetLastError()); + strError = strprintf("Error: Couldn't open socket for incoming connections (socket returned error %s)", NetworkErrorString(WSAGetLastError())); LogPrintf("%s\n", strError); return false; } @@ -1609,7 +1606,7 @@ bool BindListenPort(const CService &addrBind, string& strError) if (fcntl(hListenSocket, F_SETFL, O_NONBLOCK) == SOCKET_ERROR) #endif { - strError = strprintf("Error: Couldn't set properties on socket for incoming connections (error %d)", WSAGetLastError()); + strError = strprintf("Error: Couldn't set properties on socket for incoming connections (error %s)", NetworkErrorString(WSAGetLastError())); LogPrintf("%s\n", strError); return false; } @@ -1638,7 +1635,7 @@ bool BindListenPort(const CService &addrBind, string& strError) if (nErr == WSAEADDRINUSE) strError = strprintf(_("Unable to bind to %s on this computer. Bitcoin Core is probably already running."), addrBind.ToString()); else - strError = strprintf(_("Unable to bind to %s on this computer (bind returned error %d, %s)"), addrBind.ToString(), nErr, strerror(nErr)); + strError = strprintf(_("Unable to bind to %s on this computer (bind returned error %s)"), addrBind.ToString(), NetworkErrorString(nErr)); LogPrintf("%s\n", strError); return false; } @@ -1647,7 +1644,7 @@ bool BindListenPort(const CService &addrBind, string& strError) // Listen for incoming connections if (listen(hListenSocket, SOMAXCONN) == SOCKET_ERROR) { - strError = strprintf(_("Error: Listening for incoming connections failed (listen returned error %d)"), WSAGetLastError()); + strError = strprintf(_("Error: Listening for incoming connections failed (listen returned error %s)"), NetworkErrorString(WSAGetLastError())); LogPrintf("%s\n", strError); return false; } @@ -1785,7 +1782,7 @@ public: BOOST_FOREACH(SOCKET hListenSocket, vhListenSocket) if (hListenSocket != INVALID_SOCKET) if (closesocket(hListenSocket) == SOCKET_ERROR) - LogPrintf("closesocket(hListenSocket) failed with error %d\n", WSAGetLastError()); + LogPrintf("closesocket(hListenSocket) failed with error %s\n", NetworkErrorString(WSAGetLastError())); // clean up some globals (to help leak detection) BOOST_FOREACH(CNode *pnode, vNodes) @@ -49,6 +49,7 @@ void AddressCurrentlyConnected(const CService& addr); CNode* FindNode(const CNetAddr& ip); CNode* FindNode(const CService& ip); CNode* ConnectNode(CAddress addrConnect, const char *strDest = NULL); +bool OpenNetworkConnection(const CAddress& addrConnect, CSemaphoreGrant *grantOutbound = NULL, const char *strDest = NULL, bool fOneShot = false); void MapPort(bool fUseUPnP); unsigned short GetListenPort(); bool BindListenPort(const CService &bindAddr, std::string& strError=REF(std::string())); diff --git a/src/netbase.cpp b/src/netbase.cpp index 82a681281d..4aa7367f39 100644 --- a/src/netbase.cpp +++ b/src/netbase.cpp @@ -123,11 +123,6 @@ bool LookupHost(const char *pszName, std::vector<CNetAddr>& vIP, unsigned int nM return LookupIntern(strHost.c_str(), vIP, nMaxSolutions, fAllowLookup); } -bool LookupHostNumeric(const char *pszName, std::vector<CNetAddr>& vIP, unsigned int nMaxSolutions) -{ - return LookupHost(pszName, vIP, nMaxSolutions, false); -} - bool Lookup(const char *pszName, std::vector<CService>& vAddr, int portDefault, bool fAllowLookup, unsigned int nMaxSolutions) { if (pszName[0] == 0) @@ -361,7 +356,7 @@ bool static ConnectSocketDirectly(const CService &addrConnect, SOCKET& hSocketRe } if (nRet == SOCKET_ERROR) { - LogPrintf("select() for %s failed: %i\n", addrConnect.ToString(), WSAGetLastError()); + LogPrintf("select() for %s failed: %s\n", addrConnect.ToString(), NetworkErrorString(WSAGetLastError())); closesocket(hSocket); return false; } @@ -372,13 +367,13 @@ bool static ConnectSocketDirectly(const CService &addrConnect, SOCKET& hSocketRe if (getsockopt(hSocket, SOL_SOCKET, SO_ERROR, &nRet, &nRetSize) == SOCKET_ERROR) #endif { - LogPrintf("getsockopt() for %s failed: %i\n", addrConnect.ToString(), WSAGetLastError()); + LogPrintf("getsockopt() for %s failed: %s\n", addrConnect.ToString(), NetworkErrorString(WSAGetLastError())); closesocket(hSocket); return false; } if (nRet != 0) { - LogPrintf("connect() to %s failed after select(): %s\n", addrConnect.ToString(), strerror(nRet)); + LogPrintf("connect() to %s failed after select(): %s\n", addrConnect.ToString(), NetworkErrorString(nRet)); closesocket(hSocket); return false; } @@ -389,7 +384,7 @@ bool static ConnectSocketDirectly(const CService &addrConnect, SOCKET& hSocketRe else #endif { - LogPrintf("connect() to %s failed: %i\n", addrConnect.ToString(), WSAGetLastError()); + LogPrintf("connect() to %s failed: %s\n", addrConnect.ToString(), NetworkErrorString(WSAGetLastError())); closesocket(hSocket); return false; } @@ -1237,3 +1232,36 @@ bool operator!=(const CSubNet& a, const CSubNet& b) { return !(a==b); } + +#ifdef WIN32 +std::string NetworkErrorString(int err) +{ + char buf[256]; + buf[0] = 0; + if(FormatMessageA(FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS | FORMAT_MESSAGE_MAX_WIDTH_MASK, + NULL, err, MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), + buf, sizeof(buf), NULL)) + { + return strprintf("%s (%d)", buf, err); + } + else + { + return strprintf("Unknown error (%d)", err); + } +} +#else +std::string NetworkErrorString(int err) +{ + char buf[256]; + const char *s = buf; + buf[0] = 0; + /* Too bad there are two incompatible implementations of the + * thread-safe strerror. */ +#ifdef STRERROR_R_CHAR_P /* GNU variant can return a pointer outside the passed buffer */ + s = strerror_r(err, buf, sizeof(buf)); +#else /* POSIX variant always returns message in buffer */ + (void) strerror_r(err, buf, sizeof(buf)); +#endif + return strprintf("%s (%d)", s, err); +} +#endif diff --git a/src/netbase.h b/src/netbase.h index 118f866d6c..f5a64cb51f 100644 --- a/src/netbase.h +++ b/src/netbase.h @@ -173,11 +173,12 @@ bool IsProxy(const CNetAddr &addr); bool SetNameProxy(CService addrProxy, int nSocksVersion = 5); bool HaveNameProxy(); bool LookupHost(const char *pszName, std::vector<CNetAddr>& vIP, unsigned int nMaxSolutions = 0, bool fAllowLookup = true); -bool LookupHostNumeric(const char *pszName, std::vector<CNetAddr>& vIP, unsigned int nMaxSolutions = 0); bool Lookup(const char *pszName, CService& addr, int portDefault = 0, bool fAllowLookup = true); bool Lookup(const char *pszName, std::vector<CService>& vAddr, int portDefault = 0, bool fAllowLookup = true, unsigned int nMaxSolutions = 0); bool LookupNumeric(const char *pszName, CService& addr, int portDefault = 0); bool ConnectSocket(const CService &addr, SOCKET& hSocketRet, int nTimeout = nConnectTimeout); bool ConnectSocketByName(CService &addr, SOCKET& hSocketRet, const char *pszDest, int portDefault = 0, int nTimeout = nConnectTimeout); +/** Return readable error string for a network error code */ +std::string NetworkErrorString(int err); #endif diff --git a/src/qt/guiutil.cpp b/src/qt/guiutil.cpp index 7b264d27c7..49c0867450 100644 --- a/src/qt/guiutil.cpp +++ b/src/qt/guiutil.cpp @@ -76,7 +76,11 @@ QString dateTimeStr(qint64 nTime) QFont bitcoinAddressFont() { QFont font("Monospace"); +#if QT_VERSION >= 0x040800 + font.setStyleHint(QFont::Monospace); +#else font.setStyleHint(QFont::TypeWriter); +#endif return font; } diff --git a/src/qt/locale/bitcoin_da.ts b/src/qt/locale/bitcoin_da.ts index 5795701497..b13b38a878 100644 --- a/src/qt/locale/bitcoin_da.ts +++ b/src/qt/locale/bitcoin_da.ts @@ -25,7 +25,7 @@ Produktet indeholder software som er udviklet af OpenSSL Project til brug i Open </message> <message> <source>Copyright</source> - <translation>Copyright</translation> + <translation>Ophavsret</translation> </message> <message> <source>The Bitcoin Core developers</source> @@ -76,7 +76,7 @@ Produktet indeholder software som er udviklet af OpenSSL Project til brug i Open </message> <message> <source>&Export</source> - <translation>Eksporter</translation> + <translation>Eksportér</translation> </message> <message> <source>&Delete</source> @@ -214,7 +214,7 @@ Produktet indeholder software som er udviklet af OpenSSL Project til brug i Open </message> <message> <source>IMPORTANT: Any previous backups you have made of your wallet file should be replaced with the newly generated, encrypted wallet file. For security reasons, previous backups of the unencrypted wallet file will become useless as soon as you start using the new, encrypted wallet.</source> - <translation>VIGTIGT: Enhver tidligere sikkerhedskopi, som du har lavet af tegnebogsfilen, bør blive erstattet af den nyligt genererede, krypterede tegnebogsfil. Af sikkerhedsmæssige årsager vil tidligere sikkerhedskopier af den ikke-krypterede tegnebogsfil blive ubrugelig i det øjeblik, du starter med at anvende den nye, krypterede tegnebog.</translation> + <translation>VIGTIGT: Enhver tidligere sikkerhedskopi, som du har lavet af tegnebogsfilen, bør blive erstattet af den nyligt genererede, krypterede tegnebogsfil. Af sikkerhedsmæssige årsager vil tidligere sikkerhedskopier af den ikke-krypterede tegnebogsfil blive ubrugelige i det øjeblik, du starter med at anvende den nye, krypterede tegnebog.</translation> </message> <message> <source>Warning: The Caps Lock key is on!</source> @@ -337,11 +337,11 @@ Produktet indeholder software som er udviklet af OpenSSL Project til brug i Open </message> <message> <source>Importing blocks from disk...</source> - <translation>Importerer blokke fra disken...</translation> + <translation>Importerer blokke fra disken …</translation> </message> <message> <source>Reindexing blocks on disk...</source> - <translation>Genindekserer blokke på disken...</translation> + <translation>Genindekserer blokke på disken …</translation> </message> <message> <source>Send coins to a Bitcoin address</source> @@ -397,7 +397,7 @@ Produktet indeholder software som er udviklet af OpenSSL Project til brug i Open </message> <message> <source>Encrypt the private keys that belong to your wallet</source> - <translation>Krypter de private nøgler, der hører til din tegnebog</translation> + <translation>Kryptér de private nøgler, der hører til din tegnebog</translation> </message> <message> <source>Sign messages with your Bitcoin addresses to prove you own them</source> @@ -405,7 +405,7 @@ Produktet indeholder software som er udviklet af OpenSSL Project til brug i Open </message> <message> <source>Verify messages to ensure they were signed with specified Bitcoin addresses</source> - <translation>Verificér beskeder for at sikre, at de er underskrevet med de(n) angivne Bitcoin-adresse(r)</translation> + <translation>Verificér beskeder for at sikre, at de er underskrevet med de angivne Bitcoin-adresser</translation> </message> <message> <source>&File</source> @@ -469,7 +469,7 @@ Produktet indeholder software som er udviklet af OpenSSL Project til brug i Open </message> <message> <source>No block source available...</source> - <translation>Ingen blokkilde tilgængelig...</translation> + <translation>Ingen blokkilde tilgængelig …</translation> </message> <message> <source>Processed %1 of %2 (estimated) blocks of transaction history.</source> @@ -861,7 +861,7 @@ Adresse: %4 <name>FreespaceChecker</name> <message> <source>A new data directory will be created.</source> - <translation type="unfinished"/> + <translation>En ny datamappe vil blive oprettet.</translation> </message> <message> <source>name</source> @@ -869,15 +869,15 @@ Adresse: %4 </message> <message> <source>Directory already exists. Add %1 if you intend to create a new directory here.</source> - <translation type="unfinished"/> + <translation>Mappe eksisterer allerede. Tilføj %1, hvis du vil oprette en ny mappe her.</translation> </message> <message> <source>Path already exists, and is not a directory.</source> - <translation type="unfinished"/> + <translation>Sti eksisterer allerede og er ikke en mappe.</translation> </message> <message> <source>Cannot create data directory here.</source> - <translation type="unfinished"/> + <translation>Kan ikke oprette en mappe her.</translation> </message> </context> <context> @@ -947,11 +947,11 @@ Adresse: %4 </message> <message> <source>Use the default data directory</source> - <translation type="unfinished"/> + <translation>Brug standardmappen for data</translation> </message> <message> <source>Use a custom data directory:</source> - <translation type="unfinished"/> + <translation>Brug tilpasset mappe for data:</translation> </message> <message> <source>Bitcoin</source> @@ -967,11 +967,11 @@ Adresse: %4 </message> <message> <source>GB of free space available</source> - <translation type="unfinished"/> + <translation>GB fri plads tilgængelig</translation> </message> <message> <source>(of %1GB needed)</source> - <translation type="unfinished"/> + <translation>(ud af %1 GB behøvet)</translation> </message> </context> <context> @@ -1133,15 +1133,15 @@ Adresse: %4 </message> <message> <source>&Minimize to the tray instead of the taskbar</source> - <translation>Minimer til statusfeltet i stedet for proceslinjen</translation> + <translation>Minimér til statusfeltet i stedet for proceslinjen</translation> </message> <message> <source>Minimize instead of exit the application when the window is closed. When this option is enabled, the application will be closed only after selecting Quit in the menu.</source> - <translation>Minimer i stedet for at afslutte programmet, når vinduet lukkes. Når denne indstilling er valgt, vil programmet kun blive lukket, når du har valgt Afslut i menuen.</translation> + <translation>Minimér i stedet for at afslutte programmet, når vinduet lukkes. Når denne indstilling er valgt, vil programmet kun blive lukket, når du har valgt Afslut i menuen.</translation> </message> <message> <source>M&inimize on close</source> - <translation>Minimer ved lukning</translation> + <translation>Minimér ved lukning</translation> </message> <message> <source>&Display</source> @@ -1149,11 +1149,11 @@ Adresse: %4 </message> <message> <source>User Interface &language:</source> - <translation>Brugergrænsefladesprog:</translation> + <translation>Sprog for brugergrænseflade:</translation> </message> <message> <source>The user interface language can be set here. This setting will take effect after restarting Bitcoin.</source> - <translation>Brugergrænsefladesproget kan angives her. Denne indstilling træder først i kraft, når Bitcoin genstartes.</translation> + <translation>Sproget for brugergrænsefladen kan angives her. Denne indstilling træder først i kraft, når Bitcoin genstartes.</translation> </message> <message> <source>&Unit to show amounts in:</source> @@ -1161,7 +1161,7 @@ Adresse: %4 </message> <message> <source>Choose the default subdivision unit to show in the interface and when sending coins.</source> - <translation>Vælg den standard underopdelingsenhed, som skal vises i brugergrænsefladen og ved afsendelse af bitcoins.</translation> + <translation>Vælg standard for underopdeling af enhed, som skal vises i brugergrænsefladen og ved afsendelse af bitcoins.</translation> </message> <message> <source>Whether to show Bitcoin addresses in the transaction list or not.</source> @@ -1181,7 +1181,7 @@ Adresse: %4 </message> <message> <source>&Cancel</source> - <translation>Annuller</translation> + <translation>Annullér</translation> </message> <message> <source>default</source> @@ -1209,7 +1209,7 @@ Adresse: %4 </message> <message> <source>The supplied proxy address is invalid.</source> - <translation>Ugyldig proxy-adresse</translation> + <translation>Den angivne proxy-adresse er ugyldig.</translation> </message> </context> <context> @@ -1240,7 +1240,7 @@ Adresse: %4 </message> <message> <source>Total of transactions that have yet to be confirmed, and do not yet count toward the spendable balance</source> - <translation>Total transaktioner, som ikke er blevet bekræftet endnu, og som ikke endnu er en del af den nuværende saldo</translation> + <translation>Total saldo for transaktioner, som ikke er blevet bekræftet endnu, og som ikke endnu er en del af den tilgængelige saldo</translation> </message> <message> <source>Immature:</source> @@ -1283,7 +1283,7 @@ Adresse: %4 </message> <message> <source>Payment request error</source> - <translation>Fejl i betalingsforespørgelse</translation> + <translation>Fejl i betalingsforespørgsel</translation> </message> <message> <source>Cannot start bitcoin: click-to-pay handler</source> @@ -1335,7 +1335,7 @@ Adresse: %4 </message> <message> <source>Network request error</source> - <translation type="unfinished"/> + <translation>Fejl i netværksforespørgsel</translation> </message> </context> <context> @@ -1346,7 +1346,7 @@ Adresse: %4 </message> <message> <source>Error: Specified data directory "%1" does not exist.</source> - <translation type="unfinished"/> + <translation>Fejl: Angivet datamappe "%1" eksisterer ikke.</translation> </message> <message> <source>Error: Cannot parse configuration file: %1. Only use key=value syntax.</source> @@ -1354,7 +1354,7 @@ Adresse: %4 </message> <message> <source>Error: Invalid combination of -regtest and -testnet.</source> - <translation type="unfinished"/> + <translation>Fejl: Ugyldig kombination af -regtest og -testnet.</translation> </message> <message> <source>Bitcoin Core didn't yet exit safely...</source> @@ -1362,7 +1362,7 @@ Adresse: %4 </message> <message> <source>Enter a Bitcoin address (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source> - <translation>Indtast en Bitcoin-adresse (f.eks. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation> + <translation>Indtast en Bitcoin-adresse (fx 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation> </message> </context> <context> @@ -1484,7 +1484,7 @@ Adresse: %4 </message> <message> <source>Open the Bitcoin debug log file from the current data directory. This can take a few seconds for large log files.</source> - <translation>Åbn Bitcoin-fejlsøgningslogfilen fra det nuværende datakatalog. Dette kan tage nogle få sekunder for en store logfiler.</translation> + <translation>Åbn Bitcoin-fejlsøgningslogfilen fra den nuværende datamappe. Dette kan tage nogle få sekunder for store logfiler.</translation> </message> <message> <source>Clear console</source> @@ -1880,7 +1880,7 @@ Adresse: %4 </message> <message> <source>Are you sure you want to send?</source> - <translation>Er du sikker på at du vil sende?</translation> + <translation>Er du sikker på, at du vil sende?</translation> </message> <message> <source>added as transaction fee</source> @@ -1888,7 +1888,7 @@ Adresse: %4 </message> <message> <source>Payment request expired</source> - <translation>Betalingsforespørgsel udløb</translation> + <translation>Betalingsforespørgsel udløbet</translation> </message> <message> <source>Invalid payment address %1</source> @@ -1907,7 +1907,7 @@ Adresse: %4 </message> <message> <source>The address to send the payment to (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source> - <translation>Bitcoin-adressen som betalingen skal sendes til (f.eks. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation> + <translation>Bitcoin-adressen som betalingen skal sendes til (fx 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation> </message> <message> <source>Enter a label for this address to add it to your address book</source> @@ -1997,7 +1997,7 @@ Adresse: %4 </message> <message> <source>The address to sign the message with (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source> - <translation>Bitcoin-adressen som beskeden skal underskrives med (f.eks. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation> + <translation>Bitcoin-adressen som beskeden skal underskrives med (fx 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation> </message> <message> <source>Choose previously used address</source> @@ -2017,7 +2017,7 @@ Adresse: %4 </message> <message> <source>Enter the message you want to sign here</source> - <translation>Indtast beskeden, du ønsker at underskrive</translation> + <translation>Indtast her beskeden, du ønsker at underskrive</translation> </message> <message> <source>Signature</source> @@ -2025,7 +2025,7 @@ Adresse: %4 </message> <message> <source>Copy the current signature to the system clipboard</source> - <translation>Kopier den nuværende underskrift til systemets udklipsholder</translation> + <translation>Kopiér den nuværende underskrift til systemets udklipsholder</translation> </message> <message> <source>Sign the message to prove you own this Bitcoin address</source> @@ -2049,11 +2049,11 @@ Adresse: %4 </message> <message> <source>Enter the signing address, message (ensure you copy line breaks, spaces, tabs, etc. exactly) and signature below to verify the message. Be careful not to read more into the signature than what is in the signed message itself, to avoid being tricked by a man-in-the-middle attack.</source> - <translation>Indtast den underskrevne adresse, beskeden (inkluder linjeskift, mellemrum mv. nøjagtigt, som de fremgår) og underskriften for at verificére beskeden. Vær forsigtig med ikke at lægge mere i underskriften end besked selv, så du undgår at blive narret af et man-in-the-middle-angreb.</translation> + <translation>Indtast herunder den underskrivende adresse, beskeden (inkludér linjeskift, mellemrum mv. nøjagtigt, som de fremgår) og underskriften for at verificere beskeden. Vær forsigtig med ikke at lægge mere i underskriften end besked selv, så du undgår at blive narret af et man-in-the-middle-angreb.</translation> </message> <message> <source>The address the message was signed with (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source> - <translation>Bitcoin-adressen som beskeden er underskrevet med (f.eks. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation> + <translation>Bitcoin-adressen som beskeden er underskrevet med (fx 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation> </message> <message> <source>Verify the message to ensure it was signed with the specified Bitcoin address</source> @@ -2069,7 +2069,7 @@ Adresse: %4 </message> <message> <source>Enter a Bitcoin address (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source> - <translation>Indtast en Bitcoin-adresse (f.eks. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation> + <translation>Indtast en Bitcoin-adresse (fx 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation> </message> <message> <source>Click "Sign Message" to generate signature</source> @@ -2081,7 +2081,7 @@ Adresse: %4 </message> <message> <source>Please check the address and try again.</source> - <translation>Tjek venligst adressen, og forsøg igen.</translation> + <translation>Tjek venligst adressen og forsøg igen.</translation> </message> <message> <source>The entered address does not refer to a key.</source> @@ -2117,11 +2117,11 @@ Adresse: %4 </message> <message> <source>Message verification failed.</source> - <translation>Verificéring af besked mislykkedes.</translation> + <translation>Verificering af besked mislykkedes.</translation> </message> <message> <source>Message verified.</source> - <translation>Besked verificéret.</translation> + <translation>Besked verificeret.</translation> </message> </context> <context> @@ -2136,7 +2136,7 @@ Adresse: %4 </message> <message> <source>[testnet]</source> - <translation>[testnet]</translation> + <translation>[testnetværk]</translation> </message> </context> <context> @@ -2174,7 +2174,7 @@ Adresse: %4 </message> <message numerus="yes"> <source>, broadcast through %n node(s)</source> - <translation><numerusform>, transmitteret igennem %n knude(r)</numerusform><numerusform>, transmitteret igennem %n knude(r)</numerusform></translation> + <translation><numerusform>, transmitteret igennem %n knude</numerusform><numerusform>, transmitteret igennem %n knuder</numerusform></translation> </message> <message> <source>Date</source> @@ -2210,7 +2210,7 @@ Adresse: %4 </message> <message numerus="yes"> <source>matures in %n more block(s)</source> - <translation><numerusform>modner efter yderligere %n blok(ke)</numerusform><numerusform>modner efter yderligere %n blok(ke)</numerusform></translation> + <translation><numerusform>modner efter yderligere %n blok</numerusform><numerusform>modner efter yderligere %n blokke</numerusform></translation> </message> <message> <source>not accepted</source> @@ -2238,7 +2238,7 @@ Adresse: %4 </message> <message> <source>Transaction ID</source> - <translation>Transaktionens ID</translation> + <translation>Transaktions-ID</translation> </message> <message> <source>Merchant</source> @@ -2471,7 +2471,7 @@ Adresse: %4 </message> <message> <source>Copy transaction ID</source> - <translation>Kopier transaktionens ID</translation> + <translation>Kopiér transaktions-ID</translation> </message> <message> <source>Edit label</source> @@ -2560,7 +2560,7 @@ Adresse: %4 <name>WalletView</name> <message> <source>&Export</source> - <translation>Eksporter</translation> + <translation>Eksportér</translation> </message> <message> <source>Export the data in the current tab to a file</source> @@ -2568,7 +2568,7 @@ Adresse: %4 </message> <message> <source>Backup Wallet</source> - <translation>Sikkerhedskopier tegnebog</translation> + <translation>Sikkerhedskopiér tegnebog</translation> </message> <message> <source>Wallet Data (*.dat)</source> @@ -2576,7 +2576,7 @@ Adresse: %4 </message> <message> <source>Backup Failed</source> - <translation>Foretagelse af sikkerhedskopi fejlede</translation> + <translation>Sikkerhedskopiering mislykkedes</translation> </message> <message> <source>There was an error trying to save the wallet data to %1.</source> @@ -2588,7 +2588,7 @@ Adresse: %4 </message> <message> <source>Backup Successful</source> - <translation>Sikkerhedskopieret problemfri</translation> + <translation>Sikkerhedskopiering problemfri</translation> </message> </context> <context> @@ -2619,7 +2619,7 @@ Adresse: %4 </message> <message> <source>Specify data directory</source> - <translation>Angiv datakatalog</translation> + <translation>Angiv datamappe</translation> </message> <message> <source>Listen for connections on <port> (default: 8333 or testnet: 18333)</source> @@ -2671,7 +2671,7 @@ Adresse: %4 </message> <message> <source>Accept connections from outside (default: 1 if no -proxy or -connect)</source> - <translation>Accepter forbindelser udefra (standard: 1 hvis hverken -proxy eller -connect)</translation> + <translation>Acceptér forbindelser udefra (standard: 1 hvis hverken -proxy eller -connect)</translation> </message> <message> <source>%s, you must set a rpcpassword in the configuration file: @@ -2694,7 +2694,7 @@ rpcpassword=%s Brugernavnet og adgangskode MÅ IKKE være det samme. Hvis filen ikke eksisterer, opret den og giv ingen andre end ejeren læserettighed. Det anbefales også at angive alertnotify, så du påmindes om problemer; -f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com +fx: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com </translation> </message> <message> @@ -2731,7 +2731,7 @@ f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com </message> <message> <source>Error: This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds!</source> - <translation>Fejl: Denne transaktion kræver et transaktionsgebyr på minimum %s pga. dens størrelse, kompleksitet eller anvendelse af nyligt modtagne bitcoins!</translation> + <translation>Fejl: Denne transaktion kræver et transaktionsgebyr på minimum %s pga. dens beløb, kompleksitet eller anvendelse af nyligt modtagne bitcoins!</translation> </message> <message> <source>Execute command when a wallet transaction changes (%s in cmd is replaced by TxID)</source> @@ -2783,11 +2783,11 @@ f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com </message> <message> <source>Warning: The network does not appear to fully agree! Some miners appear to be experiencing issues.</source> - <translation type="unfinished"/> + <translation>Advarsel: Netværket ser ikke ud til at være fuldt ud enige! Enkelte minere ser ud til at opleve problemer.</translation> </message> <message> <source>Warning: We do not appear to fully agree with our peers! You may need to upgrade, or other nodes may need to upgrade.</source> - <translation type="unfinished"/> + <translation>Advarsel: Vi ser ikke ud til at være fuldt ud enige med andre noder! Du kan være nødt til at opgradere, eller andre noder kan være nødt til at opgradere.</translation> </message> <message> <source>Warning: error reading wallet.dat! All keys read correctly, but transaction data or address book entries might be missing or incorrect.</source> @@ -2795,7 +2795,7 @@ f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com </message> <message> <source>Warning: wallet.dat corrupt, data salvaged! Original wallet.dat saved as wallet.{timestamp}.bak in %s; if your balance or transactions are incorrect you should restore from a backup.</source> - <translation>Advarsel: wallet.dat ødelagt, data reddet! Oprindelig wallet.net gemt som wallet.{timestamp}.bak i %s; hvis din saldo eller dine transaktioner er forkert, bør du genskabe fra en sikkerhedskopi.</translation> + <translation>Advarsel: wallet.dat ødelagt, data reddet! Oprindelig wallet.dat gemt som wallet.{timestamp}.bak i %s; hvis din saldo eller dine transaktioner er forkert, bør du genskabe fra en sikkerhedskopi.</translation> </message> <message> <source>(default: 1)</source> @@ -2947,7 +2947,7 @@ f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com </message> <message> <source>Find peers using DNS lookup (default: 1 unless -connect)</source> - <translation>Find ligeværdige ved DNS-opslag (standard: 1 hvis ikke -connect)</translation> + <translation>Find andre knuder ved DNS-opslag (standard: 1 hvis ikke -connect)</translation> </message> <message> <source>Force safe mode (default: 0)</source> @@ -2955,11 +2955,11 @@ f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com </message> <message> <source>Generate coins (default: 0)</source> - <translation>Generer bitcoins (standard: 0)</translation> + <translation>Generér bitcoins (standard: 0)</translation> </message> <message> <source>How many blocks to check at startup (default: 288, 0 = all)</source> - <translation>Antal blokke som tjekkes ved opstart (0=alle, standard: 288)</translation> + <translation>Antal blokke som tjekkes ved opstart (standard: 288, 0=alle)</translation> </message> <message> <source>If <category> is not supplied, output all debugging information.</source> @@ -2971,7 +2971,7 @@ f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com </message> <message> <source>Incorrect or no genesis block found. Wrong datadir for network?</source> - <translation type="unfinished"/> + <translation>Ukorrekt eller ingen tilblivelsesblok fundet. Forkert datamappe for netværk?</translation> </message> <message> <source>Invalid -onion address: '%s'</source> @@ -3011,7 +3011,7 @@ f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com </message> <message> <source>Specify wallet file (within data directory)</source> - <translation type="unfinished"/> + <translation>Angiv tegnebogsfil (inden for datamappe)</translation> </message> <message> <source>Spend unconfirmed change when sending transactions (default: 1)</source> @@ -3027,11 +3027,11 @@ f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com </message> <message> <source>Verifying blocks...</source> - <translation>Verificerer blokke...</translation> + <translation>Verificerer blokke …</translation> </message> <message> <source>Verifying wallet...</source> - <translation>Verificerer tegnebog...</translation> + <translation>Verificerer tegnebog …</translation> </message> <message> <source>Wait for RPC server to start</source> @@ -3039,7 +3039,7 @@ f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com </message> <message> <source>Wallet %s resides outside data directory %s</source> - <translation type="unfinished"/> + <translation>Tegnebog %1 findes uden for datamappe %s</translation> </message> <message> <source>Wallet options:</source> @@ -3051,7 +3051,7 @@ f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com </message> <message> <source>You need to rebuild the database using -reindex to change -txindex</source> - <translation type="unfinished"/> + <translation>Du er nødt til at genopbygge databasen ved hjælp af -reindex for at ændre -txindex</translation> </message> <message> <source>Imports blocks from external blk000??.dat file</source> @@ -3063,7 +3063,7 @@ f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com </message> <message> <source>Execute command when a relevant alert is received or we see a really long fork (%s in cmd is replaced by message)</source> - <translation type="unfinished"/> + <translation>Udfør kommando, når en relevant alarm modtages eller vi ser en virkelig lang udsplitning (%s i cmd erstattes af besked)</translation> </message> <message> <source>Output debugging information (default: 0, supplying <category> is optional)</source> @@ -3079,11 +3079,11 @@ f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com </message> <message> <source>Invalid amount for -minrelaytxfee=<amount>: '%s'</source> - <translation>Ugyldigt beløb til -minrelaytxfee=<beløb>:'%s'</translation> + <translation>Ugyldigt beløb til -minrelaytxfee=<beløb>: "%s"</translation> </message> <message> <source>Invalid amount for -mintxfee=<amount>: '%s'</source> - <translation>Ugyldigt beløb til -mintxfee=<beløb>:'%s'</translation> + <translation>Ugyldigt beløb til -mintxfee=<beløb>: "%s"</translation> </message> <message> <source>Limit size of signature cache to <n> entries (default: 50000)</source> @@ -3099,15 +3099,15 @@ f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com </message> <message> <source>Maximum per-connection receive buffer, <n>*1000 bytes (default: 5000)</source> - <translation>Maksimum for modtagelsesbuffer pr. forbindelse, <n>*1000 bytes (standard: 5000)</translation> + <translation>Maksimum for modtagelsesbuffer pr. forbindelse, <n>*1000 byte (standard: 5000)</translation> </message> <message> <source>Maximum per-connection send buffer, <n>*1000 bytes (default: 1000)</source> - <translation>Maksimum for afsendelsesbuffer pr. forbindelse, <n>*1000 bytes (standard: 1000)</translation> + <translation>Maksimum for afsendelsesbuffer pr. forbindelse, <n>*1000 byte (standard: 1000)</translation> </message> <message> <source>Only accept block chain matching built-in checkpoints (default: 1)</source> - <translation>Accepter kun blokkæde, som matcher indbyggede kontrolposter (standard: 1)</translation> + <translation>Acceptér kun blokkæde, som matcher indbyggede kontrolposter (standard: 1)</translation> </message> <message> <source>Only connect to nodes in network <net> (IPv4, IPv6 or Tor)</source> @@ -3155,7 +3155,7 @@ f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com </message> <message> <source>Set minimum block size in bytes (default: 0)</source> - <translation>Angiv minimumsblokstørrelse i bytes (standard: 0)</translation> + <translation>Angiv minimumsblokstørrelse i byte (standard: 0)</translation> </message> <message> <source>Sets the DB_PRIVATE flag in the wallet db environment (default: 1)</source> @@ -3203,11 +3203,11 @@ f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com </message> <message> <source>Use UPnP to map the listening port (default: 0)</source> - <translation>Forsøg at bruge UPnP til at konfigurere den lyttende port (standard: 0)</translation> + <translation>Brug UPnP til at konfigurere den lyttende port (standard: 0)</translation> </message> <message> <source>Use UPnP to map the listening port (default: 1 when listening)</source> - <translation>Forsøg at bruge UPnP til at konfigurere den lyttende port (standard: 1 når lytter)</translation> + <translation>Brug UPnP til at konfigurere den lyttende port (standard: 1 under lytning)</translation> </message> <message> <source>Username for JSON-RPC connections</source> @@ -3311,11 +3311,11 @@ f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com </message> <message> <source>Invalid -proxy address: '%s'</source> - <translation>Ugyldig -proxy adresse: '%s'</translation> + <translation>Ugyldig -proxy adresse: "%s"</translation> </message> <message> <source>Unknown network specified in -onlynet: '%s'</source> - <translation>Ukendt netværk anført i -onlynet: '%s'</translation> + <translation>Ukendt netværk anført i -onlynet: "%s"</translation> </message> <message> <source>Unknown -socks proxy version requested: %i</source> @@ -3323,15 +3323,15 @@ f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com </message> <message> <source>Cannot resolve -bind address: '%s'</source> - <translation>Kan ikke finde -bind adressen: '%s'</translation> + <translation>Kan ikke finde -bind adressen: "%s"</translation> </message> <message> <source>Cannot resolve -externalip address: '%s'</source> - <translation>Kan ikke finde -externalip adressen: '%s'</translation> + <translation>Kan ikke finde -externalip adressen: "%s"</translation> </message> <message> <source>Invalid amount for -paytxfee=<amount>: '%s'</source> - <translation>Ugyldigt beløb for -paytxfee=<amount>: '%s'</translation> + <translation>Ugyldigt beløb for -paytxfee=<beløb>: "%s"</translation> </message> <message> <source>Invalid amount</source> @@ -3381,7 +3381,7 @@ f.eks.: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo.com <source>You must set rpcpassword=<password> in the configuration file: %s If the file does not exist, create it with owner-readable-only file permissions.</source> - <translation>Du skal angive rpcpassword=<password> i konfigurationsfilen: + <translation>Du skal angive rpcpassword=<adgangskode> i konfigurationsfilen: %s Hvis filen ikke eksisterer, opret den og giv ingen andre end ejeren læserettighed.</translation> </message> diff --git a/src/qt/locale/bitcoin_id_ID.ts b/src/qt/locale/bitcoin_id_ID.ts index c4dee5f92d..2b9685f6a0 100644 --- a/src/qt/locale/bitcoin_id_ID.ts +++ b/src/qt/locale/bitcoin_id_ID.ts @@ -433,7 +433,7 @@ Produk ini termasuk software yang dibangun oleh Proyek OpenSSL untuk Toolkit Ope </message> <message> <source>Request payments (generates QR codes and bitcoin: URIs)</source> - <translation type="unfinished"/> + <translation>Permintaan pembayaran (membangkitkan kode QR dan bitcoin: URIs)</translation> </message> <message> <source>&About Bitcoin Core</source> @@ -473,7 +473,7 @@ Produk ini termasuk software yang dibangun oleh Proyek OpenSSL untuk Toolkit Ope </message> <message> <source>Processed %1 of %2 (estimated) blocks of transaction history.</source> - <translation type="unfinished"/> + <translation>Proses % 1 dar i% 2 (perkiraan) blok catatan transaksi</translation> </message> <message> <source>Processed %1 blocks of transaction history.</source> @@ -509,7 +509,7 @@ Produk ini termasuk software yang dibangun oleh Proyek OpenSSL untuk Toolkit Ope </message> <message> <source>Transactions after this will not yet be visible.</source> - <translation type="unfinished"/> + <translation>Transaksi setelah ini tidak akan ditampilkan</translation> </message> <message> <source>Error</source> @@ -561,7 +561,7 @@ Alamat: %4 </message> <message> <source>A fatal error occurred. Bitcoin can no longer continue safely and will quit.</source> - <translation type="unfinished"/> + <translation>Terjadi kesalahan fatal. Bitcoin tidak bisa lagi meneruskan dengan aman dan akan berhenti.</translation> </message> </context> <context> @@ -611,15 +611,15 @@ Alamat: %4 </message> <message> <source>(un)select all</source> - <translation type="unfinished"/> + <translation>(Tidak)memilih semua</translation> </message> <message> <source>Tree mode</source> - <translation type="unfinished"/> + <translation>mode pohon</translation> </message> <message> <source>List mode</source> - <translation type="unfinished"/> + <translation>Mode daftar</translation> </message> <message> <source>Amount</source> @@ -663,11 +663,11 @@ Alamat: %4 </message> <message> <source>Lock unspent</source> - <translation type="unfinished"/> + <translation>Kunci terpakai.</translation> </message> <message> <source>Unlock unspent</source> - <translation type="unfinished"/> + <translation>Membuka kunci terpakai</translation> </message> <message> <source>Copy quantity</source> @@ -1350,7 +1350,7 @@ Alamat: %4 </message> <message> <source>Error: Cannot parse configuration file: %1. Only use key=value syntax.</source> - <translation type="unfinished"/> + <translation>Kesalahan: Tidak dapat memproses pengaturan berkas: %1. Hanya menggunakan kunci= nilai sintak.</translation> </message> <message> <source>Error: Invalid combination of -regtest and -testnet.</source> @@ -1408,7 +1408,7 @@ Alamat: %4 </message> <message> <source>General</source> - <translation type="unfinished"/> + <translation>Umum</translation> </message> <message> <source>Using OpenSSL version</source> @@ -1460,7 +1460,7 @@ Alamat: %4 </message> <message> <source>&Clear</source> - <translation type="unfinished"/> + <translation>&Kosongkan</translation> </message> <message> <source>Totals</source> @@ -1504,31 +1504,31 @@ Alamat: %4 </message> <message> <source>%1 B</source> - <translation type="unfinished"/> + <translation>%1 B</translation> </message> <message> <source>%1 KB</source> - <translation type="unfinished"/> + <translation>%1 KB</translation> </message> <message> <source>%1 MB</source> - <translation type="unfinished"/> + <translation>%1 MB</translation> </message> <message> <source>%1 GB</source> - <translation type="unfinished"/> + <translation>%1 GB</translation> </message> <message> <source>%1 m</source> - <translation type="unfinished"/> + <translation>%1 menit</translation> </message> <message> <source>%1 h</source> - <translation type="unfinished"/> + <translation>%1 Jam</translation> </message> <message> <source>%1 h %2 m</source> - <translation type="unfinished"/> + <translation>%1 Jam %2 menit</translation> </message> </context> <context> @@ -1551,7 +1551,7 @@ Alamat: %4 </message> <message> <source>R&euse an existing receiving address (not recommended)</source> - <translation type="unfinished"/> + <translation>Gunakan lagi alamat penerima yang ada (tidak disarankan)</translation> </message> <message> <source>An optional message to attach to the payment request, which will be displayed when the request is opened. Note: The message will not be sent with the payment over the Bitcoin network.</source> @@ -1716,7 +1716,7 @@ Alamat: %4 </message> <message> <source>automatically selected</source> - <translation type="unfinished"/> + <translation>Pemilihan otomatis</translation> </message> <message> <source>Insufficient funds!</source> @@ -1947,7 +1947,7 @@ Alamat: %4 </message> <message> <source>This is a verified payment request.</source> - <translation type="unfinished"/> + <translation>Permintaan pembayaran terverifikasi.</translation> </message> <message> <source>Enter a label for this address to add it to the list of used addresses</source> @@ -1959,7 +1959,7 @@ Alamat: %4 </message> <message> <source>This is an unverified payment request.</source> - <translation type="unfinished"/> + <translation>Permintaan pembayaran tidak terverifikasi.</translation> </message> <message> <source>Pay To:</source> @@ -2005,7 +2005,7 @@ Alamat: %4 </message> <message> <source>Alt+A</source> - <translation>Alt+J</translation> + <translation>Alt+A</translation> </message> <message> <source>Paste address from clipboard</source> @@ -2726,7 +2726,7 @@ for example: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo. </message> <message> <source>Execute command when a wallet transaction changes (%s in cmd is replaced by TxID)</source> - <translation type="unfinished"/> + <translation>Jalankan perintah ketika perubahan transaksi dompet (%s di cmd digantikan oleh TxID)</translation> </message> <message> <source>Fees smaller than this are considered zero fee (for transaction creation) (default:</source> @@ -2790,11 +2790,11 @@ for example: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo. </message> <message> <source>(default: 1)</source> - <translation type="unfinished"/> + <translation>(pengaturan awal: 1)</translation> </message> <message> <source>(default: wallet.dat)</source> - <translation type="unfinished"/> + <translation>(pengaturan awal: wallet.dat)</translation> </message> <message> <source><category> can be:</source> @@ -2830,7 +2830,7 @@ for example: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo. </message> <message> <source>Connection options:</source> - <translation type="unfinished"/> + <translation>Pilih koneksi:</translation> </message> <message> <source>Corrupted block database detected</source> @@ -2858,11 +2858,11 @@ for example: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo. </message> <message> <source>Error initializing block database</source> - <translation type="unfinished"/> + <translation>Kesalahan menginisialisasi database blok</translation> </message> <message> <source>Error initializing wallet database environment %s!</source> - <translation type="unfinished"/> + <translation>Kesalahan menginisialisasi dompet pada database%s!</translation> </message> <message> <source>Error loading block database</source> @@ -2958,7 +2958,7 @@ for example: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo. </message> <message> <source>Importing...</source> - <translation type="unfinished"/> + <translation>mengimpor...</translation> </message> <message> <source>Incorrect or no genesis block found. Wrong datadir for network?</source> @@ -2970,7 +2970,7 @@ for example: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo. </message> <message> <source>Not enough file descriptors available.</source> - <translation type="unfinished"/> + <translation>Deskripsi berkas tidak tersedia dengan cukup.</translation> </message> <message> <source>Prepend debug output with timestamp (default: 1)</source> @@ -2978,7 +2978,7 @@ for example: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo. </message> <message> <source>RPC client options:</source> - <translation type="unfinished"/> + <translation>Pilihan RPC klien:</translation> </message> <message> <source>Rebuild block chain index from current blk000??.dat files</source> @@ -2998,7 +2998,7 @@ for example: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo. </message> <message> <source>Set the number of threads to service RPC calls (default: 4)</source> - <translation type="unfinished"/> + <translation>Mengatur jumlah urutan untuk layanan panggilan RPC (pengaturan awal: 4)</translation> </message> <message> <source>Specify wallet file (within data directory)</source> @@ -3174,11 +3174,11 @@ for example: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo. </message> <message> <source>Start Bitcoin Core Daemon</source> - <translation type="unfinished"/> + <translation>Memulai Bitcoin Core Daemon</translation> </message> <message> <source>System error: </source> - <translation type="unfinished"/> + <translation>Kesalahan sistem:</translation> </message> <message> <source>Transaction amount too small</source> diff --git a/src/qt/locale/bitcoin_ko_KR.ts b/src/qt/locale/bitcoin_ko_KR.ts index fb013f4c1d..8e2b681ba9 100644 --- a/src/qt/locale/bitcoin_ko_KR.ts +++ b/src/qt/locale/bitcoin_ko_KR.ts @@ -33,7 +33,7 @@ MIT/X11 프로그램 라이선스에 따라 배포합니다. COPYING 또는 http </message> <message> <source>(%1-bit)</source> - <translation type="unfinished"/> + <translation>(%1-비트)</translation> </message> </context> <context> @@ -611,7 +611,7 @@ Address: %4 </message> <message> <source>(un)select all</source> - <translation type="unfinished"/> + <translation>모두 선택(하지 않음)</translation> </message> <message> <source>Tree mode</source> @@ -663,11 +663,11 @@ Address: %4 </message> <message> <source>Lock unspent</source> - <translation type="unfinished"/> + <translation>비트코인이 사용되지 않은 주소를 잠금 처리합니다.</translation> </message> <message> <source>Unlock unspent</source> - <translation type="unfinished"/> + <translation>비트코인이 사용되지 않은 주소를 잠금 해제합니다. </translation> </message> <message> <source>Copy quantity</source> @@ -767,7 +767,7 @@ Address: %4 </message> <message> <source>Transactions with higher priority are more likely to get included into a block.</source> - <translation type="unfinished"/> + <translation>우선 순위가 높은 거래의 경우 블럭에 포함될 가능성이 더 많습니다.</translation> </message> <message> <source>This label turns red, if the priority is smaller than "medium".</source> @@ -779,11 +779,11 @@ Address: %4 </message> <message> <source>This means a fee of at least %1 is required.</source> - <translation type="unfinished"/> + <translation>최소 %1의 거래 수수료가 필요하다는 뜻입니다. </translation> </message> <message> <source>Amounts below 0.546 times the minimum relay fee are shown as dust.</source> - <translation type="unfinished"/> + <translation>노드 릴레이를 위한 최저 수수료의 0.546배보다 낮은 거래는 먼지 거래로 표현됩니다.</translation> </message> <message> <source>This label turns red, if the change is smaller than %1.</source> @@ -916,7 +916,7 @@ Address: %4 </message> <message> <source>Set SSL root certificates for payment request (default: -system-)</source> - <translation type="unfinished"/> + <translation>지불 요청을 위해 SSL 최상위 인증을 설정합니다. (기본값: -system-)</translation> </message> <message> <source>Show splash screen on startup (default: 1)</source> @@ -939,11 +939,11 @@ Address: %4 </message> <message> <source>As this is the first time the program is launched, you can choose where Bitcoin Core will store its data.</source> - <translation type="unfinished"/> + <translation>프로그램이 처음으로 실행되고 있습니다. 비트코인 코어가 어디에 데이터를 저장할지 선택할 수 있습니다. </translation> </message> <message> <source>Bitcoin Core will download and store a copy of the Bitcoin block chain. At least %1GB of data will be stored in this directory, and it will grow over time. The wallet will also be stored in this directory.</source> - <translation type="unfinished"/> + <translation>비트코인 코어가 블럭체인의 복사본을 다운로드 저장합니다. 적어도 %1GB의 데이터가 이 폴더에 저장되며 시간이 경과할수록 점차 증가합니다. 그리고 지갑 또한 이 폴더에 저장됩니다. </translation> </message> <message> <source>Use the default data directory</source> @@ -959,7 +959,7 @@ Address: %4 </message> <message> <source>Error: Specified data directory "%1" can not be created.</source> - <translation type="unfinished"/> + <translation>오류 : 별도 정의한 폴더명 "%1" 생성에 실패했습니다. </translation> </message> <message> <source>Error</source> @@ -1033,7 +1033,7 @@ Address: %4 </message> <message> <source>Number of script &verification threads</source> - <translation type="unfinished"/> + <translation>스크립트 인증 쓰레드의 개수</translation> </message> <message> <source>Connect to the Bitcoin network through a SOCKS proxy.</source> @@ -1081,11 +1081,11 @@ Address: %4 </message> <message> <source>Expert</source> - <translation type="unfinished"/> + <translation>전문가</translation> </message> <message> <source>Enable coin &control features</source> - <translation type="unfinished"/> + <translation>코인 상세 제어기능을 활성화합니다 - &C</translation> </message> <message> <source>If you disable the spending of unconfirmed change, the change from a transaction cannot be used until that transaction has at least one confirmation. This also affects how your balance is computed.</source> @@ -1173,7 +1173,7 @@ Address: %4 </message> <message> <source>Whether to show coin control features or not.</source> - <translation type="unfinished"/> + <translation>코인 상세 제어기능에 대한 표시 여부를 선택할 수 있습니다.</translation> </message> <message> <source>&OK</source> @@ -1197,7 +1197,7 @@ Address: %4 </message> <message> <source>Client restart required to activate changes.</source> - <translation type="unfinished"/> + <translation>변경 사항을 적용하기 위해서는 프로그램이 종료 후 재시작되어야 합니다.</translation> </message> <message> <source>Client will be shutdown, do you want to proceed?</source> @@ -1205,7 +1205,7 @@ Address: %4 </message> <message> <source>This change would require a client restart.</source> - <translation type="unfinished"/> + <translation>이 변경 사항 적용을 위해 프로그램 재시작이 필요합니다. </translation> </message> <message> <source>The supplied proxy address is invalid.</source> @@ -1279,7 +1279,7 @@ Address: %4 </message> <message> <source>Requested payment amount of %1 is too small (considered dust).</source> - <translation type="unfinished"/> + <translation>요청한 금액 %1의 양이 너무 적습니다. (스팸성 거래로 간주)</translation> </message> <message> <source>Payment request error</source> @@ -1295,7 +1295,7 @@ Address: %4 </message> <message> <source>Your active proxy doesn't support SOCKS5, which is required for payment requests via proxy.</source> - <translation type="unfinished"/> + <translation>현재의 프록시가 SOCKS5를 지원하지 않아 지불 요청을 수행할 수 없습니다. </translation> </message> <message> <source>Payment request fetch URL is invalid: %1</source> @@ -1547,11 +1547,11 @@ Address: %4 </message> <message> <source>Reuse one of the previously used receiving addresses. Reusing addresses has security and privacy issues. Do not use this unless re-generating a payment request made before.</source> - <translation type="unfinished"/> + <translation>이전에 사용된 수취용 주소를 사용할려고 합니다. 주소의 재사용은 보안과 개인정보 보호 측면에서 문제를 초래할 수 있습니다. 이전 지불 요청을 재생성하는 경우가 아니라면 주소 재사용을 권하지 않습니다. </translation> </message> <message> <source>R&euse an existing receiving address (not recommended)</source> - <translation type="unfinished"/> + <translation>현재의 수취용 주소를 재사용합니다만 권장하지는 않습니다. (R&)</translation> </message> <message> <source>An optional message to attach to the payment request, which will be displayed when the request is opened. Note: The message will not be sent with the payment over the Bitcoin network.</source> @@ -1567,7 +1567,7 @@ Address: %4 </message> <message> <source>An optional amount to request. Leave this empty or zero to not request a specific amount.</source> - <translation type="unfinished"/> + <translation>요청할 금액 입력칸으로 선택 사항입니다. 빈 칸으로 두거나 특정 금액이 필요하지 않는 경우 0을 입력하세요. </translation> </message> <message> <source>Clear all fields of the form.</source> @@ -1951,7 +1951,7 @@ Address: %4 </message> <message> <source>Enter a label for this address to add it to the list of used addresses</source> - <translation type="unfinished"/> + <translation>사용된 주소 목록에 새 주소를 추가하기 위해 제목을 입력합니다. </translation> </message> <message> <source>A message that was attached to the bitcoin: URI which will be stored with the transaction for your reference. Note: This message will not be sent over the Bitcoin network.</source> @@ -1963,7 +1963,7 @@ Address: %4 </message> <message> <source>Pay To:</source> - <translation type="unfinished"/> + <translation>송금할 대상 : </translation> </message> <message> <source>Memo:</source> @@ -2246,7 +2246,7 @@ Address: %4 </message> <message> <source>Generated coins must mature %1 blocks before they can be spent. When you generated this block, it was broadcast to the network to be added to the block chain. If it fails to get into the chain, its state will change to "not accepted" and it won't be spendable. This may occasionally happen if another node generates a block within a few seconds of yours.</source> - <translation type="unfinished"/> + <translation>신규 채굴된 코인이 사용되기 위해서는 %1 개의 블럭이 경과되어야 합니다. 블럭을 생성할 때 블럭체인에 추가되도록 네트워크에 전파되는 과정을 거치는데, 블럭체인에 포함되지 못하고 실패한다면 해당 블럭의 상태는 '미승인'으로 표현되고 비트코인 또한 사용될 수 없습니다. 이 현상은 다른 노드가 비슷한 시간대에 동시에 블럭을 생성할 때 종종 발생할 수 있습니다. </translation> </message> <message> <source>Debug information</source> @@ -2316,7 +2316,7 @@ Address: %4 </message> <message> <source>Immature (%1 confirmations, will be available after %2)</source> - <translation type="unfinished"/> + <translation>충분히 숙성되지 않은 상태 (%1 승인, %2 후에 사용 가능합니다)</translation> </message> <message numerus="yes"> <source>Open for %n more block(s)</source> @@ -2348,7 +2348,7 @@ Address: %4 </message> <message> <source>Confirming (%1 of %2 recommended confirmations)</source> - <translation type="unfinished"/> + <translation>승인 중 (권장되는 승인 회수 %2 대비 현재 승인 수 %1)</translation> </message> <message> <source>Conflicted</source> @@ -2580,7 +2580,7 @@ Address: %4 </message> <message> <source>There was an error trying to save the wallet data to %1.</source> - <translation type="unfinished"/> + <translation>지갑 데이터를 %1 폴더에 저장하는 동안 오류가 발생했습니다. </translation> </message> <message> <source>The wallet data was successfully saved to %1.</source> @@ -2659,7 +2659,7 @@ Address: %4 </message> <message> <source>Bitcoin Core RPC client version</source> - <translation type="unfinished"/> + <translation>비트코인 코어 RPC 클라이언트 버전</translation> </message> <message> <source>Run in the background as a daemon and accept commands</source> @@ -2729,7 +2729,7 @@ for example: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo. </message> <message> <source>Fees smaller than this are considered zero fee (for transaction creation) (default:</source> - <translation type="unfinished"/> + <translation>해당 금액보다 적은 수수료는 수수료 면제로 간주됩니다. (거래 생성의 목적)(기본값:</translation> </message> <message> <source>Flush database activity from memory pool to disk log every <n> megabytes (default: 100)</source> @@ -2789,11 +2789,11 @@ for example: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo. </message> <message> <source>(default: 1)</source> - <translation type="unfinished"/> + <translation>(기본값: 1)</translation> </message> <message> <source>(default: wallet.dat)</source> - <translation type="unfinished"/> + <translation>(기본값: wallet.dat)</translation> </message> <message> <source><category> can be:</source> @@ -2829,7 +2829,7 @@ for example: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo. </message> <message> <source>Connection options:</source> - <translation type="unfinished"/> + <translation>연결 설정 : </translation> </message> <message> <source>Corrupted block database detected</source> @@ -2837,7 +2837,7 @@ for example: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo. </message> <message> <source>Debugging/Testing options:</source> - <translation type="unfinished"/> + <translation>디버그 및 테스트 설정</translation> </message> <message> <source>Disable safemode, override a real safe mode event (default: 0)</source> @@ -2929,11 +2929,11 @@ for example: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo. </message> <message> <source>Fee per kB to add to transactions you send</source> - <translation type="unfinished"/> + <translation>송금 거래시 추가되는 KB 당 수수료입니다. </translation> </message> <message> <source>Fees smaller than this are considered zero fee (for relaying) (default:</source> - <translation type="unfinished"/> + <translation>해당 금액보다 적은 수수료는 수수료 면제로 간주됩니다. (릴레이 목적)(기본값:</translation> </message> <message> <source>Find peers using DNS lookup (default: 1 unless -connect)</source> @@ -2941,7 +2941,7 @@ for example: alertnotify=echo %%s | mail -s "Bitcoin Alert" admin@foo. </message> <message> <source>Force safe mode (default: 0)</source> - <translation type="unfinished"/> + <translation>안전 모드로 강제 진입하는 기능입니다.(기본값: 0) </translation> </message> <message> <source>Generate coins (default: 0)</source> diff --git a/src/qt/locale/bitcoin_ro_RO.ts b/src/qt/locale/bitcoin_ro_RO.ts index 1d9d4cc936..d09c40f62e 100644 --- a/src/qt/locale/bitcoin_ro_RO.ts +++ b/src/qt/locale/bitcoin_ro_RO.ts @@ -795,7 +795,7 @@ Adresa: %4 </message> <message> <source>change from %1 (%2)</source> - <translation type="unfinished"/> + <translation>restul de la %1 (%2)</translation> </message> <message> <source>(change)</source> @@ -1587,7 +1587,7 @@ Adresa: %4 </message> <message> <source>Show the selected request (does the same as double clicking an entry)</source> - <translation type="unfinished"/> + <translation>Arata cererea selectata (acelas lucru ca si dublu-click pe o inregistrare)</translation> </message> <message> <source>Show</source> @@ -3008,7 +3008,7 @@ spre exemplu: alertnotify=echo %%s | mail -s "Alerta Bitcoin" admin@fo </message> <message> <source>Set the number of threads to service RPC calls (default: 4)</source> - <translation type="unfinished"/> + <translation>Stabileste numarul de thread-uri care servesc apeluri RPC (implicit: 4)</translation> </message> <message> <source>Specify wallet file (within data directory)</source> diff --git a/src/qt/notificator.cpp b/src/qt/notificator.cpp index 38a029dbe5..3d588cd317 100644 --- a/src/qt/notificator.cpp +++ b/src/qt/notificator.cpp @@ -28,8 +28,10 @@ #endif +#ifdef USE_DBUS // https://wiki.ubuntu.com/NotificationDevelopmentGuidelines recommends at least 128 const int FREEDESKTOP_NOTIFICATION_ICON_SIZE = 128; +#endif Notificator::Notificator(const QString &programName, QSystemTrayIcon *trayicon, QWidget *parent) : QObject(parent), diff --git a/src/qt/test/test_main.cpp b/src/qt/test/test_main.cpp index a2adb00327..220da28cfe 100644 --- a/src/qt/test/test_main.cpp +++ b/src/qt/test/test_main.cpp @@ -1,4 +1,3 @@ -#include "bitcoin-config.h" #if defined(HAVE_CONFIG_H) #include "bitcoin-config.h" #endif diff --git a/src/rpcnet.cpp b/src/rpcnet.cpp index 024f6a09de..63eed09b64 100644 --- a/src/rpcnet.cpp +++ b/src/rpcnet.cpp @@ -166,7 +166,7 @@ Value addnode(const Array& params, bool fHelp) if (strCommand == "onetry") { CAddress addr; - ConnectNode(addr, strNode.c_str()); + OpenNetworkConnection(addr, NULL, strNode.c_str()); return Value::null; } diff --git a/src/rpcprotocol.cpp b/src/rpcprotocol.cpp index 5cbaa535ab..2718f81783 100644 --- a/src/rpcprotocol.cpp +++ b/src/rpcprotocol.cpp @@ -51,15 +51,7 @@ string HTTPPost(const string& strMsg, const map<string,string>& mapRequestHeader static string rfc1123Time() { - char buffer[64]; - time_t now; - time(&now); - struct tm* now_gmt = gmtime(&now); - string locale(setlocale(LC_TIME, NULL)); - setlocale(LC_TIME, "C"); // we want POSIX (aka "C") weekday/month strings - strftime(buffer, sizeof(buffer), "%a, %d %b %Y %H:%M:%S +0000", now_gmt); - setlocale(LC_TIME, locale.c_str()); - return string(buffer); + return DateTimeStrFormat("%a, %d %b %Y %H:%M:%S +0000", GetTime()); } string HTTPReply(int nStatus, const string& strMsg, bool keepalive) diff --git a/src/test/util_tests.cpp b/src/test/util_tests.cpp index 3811569c0a..0e53a57593 100644 --- a/src/test/util_tests.cpp +++ b/src/test/util_tests.cpp @@ -108,13 +108,11 @@ BOOST_AUTO_TEST_CASE(util_HexStr) BOOST_AUTO_TEST_CASE(util_DateTimeStrFormat) { -/*These are platform-dependant and thus removed to avoid useless test failures BOOST_CHECK_EQUAL(DateTimeStrFormat("%Y-%m-%d %H:%M:%S", 0), "1970-01-01 00:00:00"); BOOST_CHECK_EQUAL(DateTimeStrFormat("%Y-%m-%d %H:%M:%S", 0x7FFFFFFF), "2038-01-19 03:14:07"); - // Formats used within Bitcoin BOOST_CHECK_EQUAL(DateTimeStrFormat("%Y-%m-%d %H:%M:%S", 1317425777), "2011-09-30 23:36:17"); BOOST_CHECK_EQUAL(DateTimeStrFormat("%Y-%m-%d %H:%M", 1317425777), "2011-09-30 23:36"); -*/ + BOOST_CHECK_EQUAL(DateTimeStrFormat("%a, %d %b %Y %H:%M:%S +0000", 1317425777), "Fri, 30 Sep 2011 23:36:17 +0000"); } BOOST_AUTO_TEST_CASE(util_ParseParameters) diff --git a/src/util.cpp b/src/util.cpp index aa3adf89ec..336ef31725 100644 --- a/src/util.cpp +++ b/src/util.cpp @@ -14,6 +14,8 @@ #include <stdarg.h> +#include <boost/date_time/posix_time/posix_time.hpp> + #ifndef WIN32 // for posix_fallocate #ifdef __linux_ @@ -885,12 +887,6 @@ static std::string FormatException(std::exception* pex, const char* pszThread) "UNKNOWN EXCEPTION \n%s in %s \n", pszModule, pszThread); } -void LogException(std::exception* pex, const char* pszThread) -{ - std::string message = FormatException(pex, pszThread); - LogPrintf("\n%s", message); -} - void PrintExceptionContinue(std::exception* pex, const char* pszThread) { std::string message = FormatException(pex, pszThread); @@ -1400,3 +1396,13 @@ void SetupEnvironment() } #endif } + +std::string DateTimeStrFormat(const char* pszFormat, int64_t nTime) +{ + // std::locale takes ownership of the pointer + std::locale loc(std::locale::classic(), new boost::posix_time::time_facet(pszFormat)); + std::stringstream ss; + ss.imbue(loc); + ss << boost::posix_time::from_time_t(nTime); + return ss.str(); +} diff --git a/src/util.h b/src/util.h index 97185073e0..ffcb20d822 100644 --- a/src/util.h +++ b/src/util.h @@ -151,8 +151,6 @@ static inline bool error(const char* format) return false; } - -void LogException(std::exception* pex, const char* pszThread); void PrintExceptionContinue(std::exception* pex, const char* pszThread); std::string FormatMoney(int64_t n, bool fPlus=false); bool ParseMoney(const std::string& str, int64_t& nRet); @@ -325,14 +323,7 @@ inline int64_t GetTimeMicros() boost::posix_time::ptime(boost::gregorian::date(1970,1,1))).total_microseconds(); } -inline std::string DateTimeStrFormat(const char* pszFormat, int64_t nTime) -{ - time_t n = nTime; - struct tm* ptmTime = gmtime(&n); - char pszTime[200]; - strftime(pszTime, sizeof(pszTime), pszFormat, ptmTime); - return pszTime; -} +std::string DateTimeStrFormat(const char* pszFormat, int64_t nTime); inline bool IsSwitchChar(char c) { diff --git a/src/wallet.cpp b/src/wallet.cpp index fa7aecddb6..89604f96ac 100644 --- a/src/wallet.cpp +++ b/src/wallet.cpp @@ -1671,21 +1671,6 @@ void CWallet::ReserveKeyFromKeyPool(int64_t& nIndex, CKeyPool& keypool) } } -int64_t CWallet::AddReserveKey(const CKeyPool& keypool) -{ - { - LOCK2(cs_main, cs_wallet); - CWalletDB walletdb(strWalletFile); - - int64_t nIndex = 1 + *(--setKeyPool.end()); - if (!walletdb.WritePool(nIndex, keypool)) - throw runtime_error("AddReserveKey() : writing added key failed"); - setKeyPool.insert(nIndex); - return nIndex; - } - return -1; -} - void CWallet::KeepKey(int64_t nIndex) { // Remove from key pool diff --git a/src/wallet.h b/src/wallet.h index 81dfbba9cb..96074151ad 100644 --- a/src/wallet.h +++ b/src/wallet.h @@ -263,7 +263,6 @@ public: bool NewKeyPool(); bool TopUpKeyPool(unsigned int kpSize = 0); - int64_t AddReserveKey(const CKeyPool& keypool); void ReserveKeyFromKeyPool(int64_t& nIndex, CKeyPool& keypool); void KeepKey(int64_t nIndex); void ReturnKey(int64_t nIndex); |