mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-07-26 20:55:19 +03:00
57 lines
1.3 KiB
Diff
57 lines
1.3 KiB
Diff
--- ./src/bitcoin-cli.cpp
|
|
+++ ./src/bitcoin-cli.cpp
|
|
@@ -53,6 +53,16 @@
|
|
|
|
int main(int argc, char* argv[])
|
|
{
|
|
+ #ifndef WIN32
|
|
+ try
|
|
+ {
|
|
+ boost::filesystem::path::codecvt(); // Raises runtime error if current locale is invalid
|
|
+ } catch(std::runtime_error &e)
|
|
+ {
|
|
+ setenv("LC_ALL", "C", 1); // Force C locale
|
|
+ }
|
|
+ #endif
|
|
+
|
|
try
|
|
{
|
|
if(!AppInitRPC(argc, argv))
|
|
--- ./src/bitcoind.cpp
|
|
+++ ./src/bitcoind.cpp
|
|
@@ -166,6 +166,16 @@
|
|
|
|
int main(int argc, char* argv[])
|
|
{
|
|
+ #ifndef WIN32
|
|
+ try
|
|
+ {
|
|
+ boost::filesystem::path::codecvt(); // Raises runtime error if current locale is invalid
|
|
+ } catch(std::runtime_error &e)
|
|
+ {
|
|
+ setenv("LC_ALL", "C", 1); // Force C locale
|
|
+ }
|
|
+ #endif
|
|
+
|
|
bool fRet = false;
|
|
|
|
// Connect bitcoind signal handlers
|
|
--- ./src/qt/bitcoin.cpp.orig
|
|
+++ ./src/qt/bitcoin.cpp
|
|
@@ -445,6 +445,16 @@
|
|
#ifndef BITCOIN_QT_TEST
|
|
int main(int argc, char *argv[])
|
|
{
|
|
+#ifndef WIN32
|
|
+ try
|
|
+ {
|
|
+ boost::filesystem::path::codecvt(); // Raises runtime error if current locale is invalid
|
|
+ } catch(std::runtime_error &e)
|
|
+ {
|
|
+ setenv("LC_ALL", "C", 1); // Force C locale
|
|
+ }
|
|
+#endif
|
|
+
|
|
/// 1. Parse command-line options. These take precedence over anything else.
|
|
// Command-line options take precedence:
|
|
ParseParameters(argc, argv);
|