diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 000000000000..eb675401b9fd --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,279 @@ +name: Build and Release XPChain Core + +on: + push: + tags: + - 'v*' + workflow_dispatch: + inputs: + tag: + description: 'Release tag (example: v0.17.0-4)' + required: true + type: string + +permissions: + contents: write + +env: + RELEASE_TAG: ${{ github.event_name == 'workflow_dispatch' && inputs.tag || github.ref_name }} + +jobs: + linux: + name: Linux Ubuntu x86_64 + runs-on: ubuntu-22.04 + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: Install dependencies + run: | + sudo apt-get update + sudo apt-get install -y \ + build-essential libtool autotools-dev automake pkg-config bsdmainutils \ + curl git python3 + + - name: Build depends (x86_64-linux-gnu) + run: | + cd depends + make HOST=x86_64-linux-gnu FALLBACK_DOWNLOAD_PATH=https://bitcoincore.org/depends-sources -j"$(nproc)" + + - name: Build + run: | + ./autogen.sh + CONFIG_SITE=$PWD/depends/x86_64-linux-gnu/share/config.site ./configure --prefix=/ + make -j"$(nproc)" + + - name: Package + run: | + TAG="${RELEASE_TAG}" + mkdir -p dist + cp src/xpchaind src/xpchain-cli src/xpchain-tx src/qt/xpchain-qt dist/ + strip dist/xpchaind dist/xpchain-cli dist/xpchain-tx dist/xpchain-qt || true + tar -C dist -czf "xpchain-${TAG}-linux-x86_64.tar.gz" xpchaind xpchain-cli xpchain-tx xpchain-qt + + - name: Upload artifact + uses: actions/upload-artifact@v4 + with: + name: linux-x86_64 + path: xpchain-*.tar.gz + + windows64: + name: Windows x86_64 + runs-on: ubuntu-22.04 + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: Install dependencies + run: | + sudo apt-get update + sudo apt-get install -y \ + build-essential libtool autotools-dev automake pkg-config bsdmainutils curl git \ + g++-mingw-w64-x86-64 + + - name: Select posix mingw toolchain (x86_64) + run: | + sudo update-alternatives --set x86_64-w64-mingw32-g++ /usr/bin/x86_64-w64-mingw32-g++-posix + sudo update-alternatives --set x86_64-w64-mingw32-gcc /usr/bin/x86_64-w64-mingw32-gcc-posix + + - name: Build depends (x86_64-w64-mingw32) + run: | + cd depends + make HOST=x86_64-w64-mingw32 FALLBACK_DOWNLOAD_PATH=https://bitcoincore.org/depends-sources -j"$(nproc)" + + - name: Configure and build + run: | + ./autogen.sh + CONFIG_SITE=$PWD/depends/x86_64-w64-mingw32/share/config.site ./configure --prefix=/ + make -j"$(nproc)" + + - name: Package + run: | + TAG="${RELEASE_TAG}" + mkdir -p dist + cp src/xpchaind.exe src/xpchain-cli.exe src/xpchain-tx.exe src/qt/xpchain-qt.exe dist/ + x86_64-w64-mingw32-strip dist/xpchaind.exe dist/xpchain-cli.exe dist/xpchain-tx.exe dist/xpchain-qt.exe || true + cd dist + zip -9 "../xpchain-${TAG}-win64.zip" xpchaind.exe xpchain-cli.exe xpchain-tx.exe xpchain-qt.exe + + - name: Upload artifact + uses: actions/upload-artifact@v4 + with: + name: win64 + path: xpchain-*-win64.zip + + windows32: + name: Windows x86 + runs-on: ubuntu-22.04 + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: Install dependencies + run: | + sudo apt-get update + sudo apt-get install -y \ + build-essential libtool autotools-dev automake pkg-config bsdmainutils curl git \ + g++-mingw-w64-i686 mingw-w64-i686-dev + + - name: Select posix mingw toolchain (i686) + run: | + sudo update-alternatives --set i686-w64-mingw32-g++ /usr/bin/i686-w64-mingw32-g++-posix + sudo update-alternatives --set i686-w64-mingw32-gcc /usr/bin/i686-w64-mingw32-gcc-posix + + - name: Build depends (i686-w64-mingw32) + run: | + cd depends + make HOST=i686-w64-mingw32 FALLBACK_DOWNLOAD_PATH=https://bitcoincore.org/depends-sources -j"$(nproc)" + + - name: Configure and build + run: | + ./autogen.sh + CONFIG_SITE=$PWD/depends/i686-w64-mingw32/share/config.site ./configure --prefix=/ + make -j"$(nproc)" + + - name: Package + run: | + TAG="${RELEASE_TAG}" + mkdir -p dist + cp src/xpchaind.exe src/xpchain-cli.exe src/xpchain-tx.exe src/qt/xpchain-qt.exe dist/ + i686-w64-mingw32-strip dist/xpchaind.exe dist/xpchain-cli.exe dist/xpchain-tx.exe dist/xpchain-qt.exe || true + cd dist + zip -9 "../xpchain-${TAG}-win32.zip" xpchaind.exe xpchain-cli.exe xpchain-tx.exe xpchain-qt.exe + + - name: Upload artifact + uses: actions/upload-artifact@v4 + with: + name: win32 + path: xpchain-*-win32.zip + + macos: + name: macOS arm64/x86_64 runner build + runs-on: macos-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: Install dependencies + run: | + brew update + brew install autoconf automake libtool pkg-config openssl@3 libevent boost berkeley-db@4 miniupnpc protobuf@21 qt@5 qrencode create-dmg + + - name: Build + run: | + BREW_PREFIX="$(brew --prefix)" + BOOST_PREFIX="$(brew --prefix boost)" + PROTOBUF_PREFIX="$(brew --prefix protobuf@21)" + export BOOST_ROOT="${BOOST_PREFIX}" + export BOOST_INCLUDEDIR="${BOOST_PREFIX}/include" + export BOOST_LIBRARYDIR="${BOOST_PREFIX}/lib" + export BOOST_LDFLAGS="-L${BOOST_PREFIX}/lib" + export PATH="${PROTOBUF_PREFIX}/bin:${PATH}" + export LDFLAGS="-L${BREW_PREFIX}/opt/openssl@3/lib -L${BREW_PREFIX}/opt/berkeley-db@4/lib -L${PROTOBUF_PREFIX}/lib" + export CPPFLAGS="-I${BREW_PREFIX}/opt/openssl@3/include -I${BREW_PREFIX}/opt/berkeley-db@4/include -I${BREW_PREFIX}/opt/boost/include -I${PROTOBUF_PREFIX}/include" + export PKG_CONFIG_PATH="${PROTOBUF_PREFIX}/lib/pkgconfig:${BREW_PREFIX}/opt/openssl@3/lib/pkgconfig:${BREW_PREFIX}/opt/qt@5/lib/pkgconfig" + ./autogen.sh + ./configure --with-gui=qt5 \ + --disable-tests \ + --disable-bench \ + --with-incompatible-bdb \ + --with-boost="${BOOST_PREFIX}" \ + --with-boost-libdir="${BOOST_PREFIX}/lib" + make -j"$(sysctl -n hw.ncpu)" + + - name: Package + run: | + TAG="${RELEASE_TAG}" + mkdir -p dist + cp src/xpchaind src/xpchain-cli src/xpchain-tx dist/ + if [ -f src/qt/xpchain-qt ]; then + cp src/qt/xpchain-qt dist/ + make appbundle + QT5_PREFIX="$(brew --prefix qt@5)" + "${QT5_PREFIX}/bin/macdeployqt" XPChain-Qt.app -verbose=1 + BOOST_LIBDIR="$(brew --prefix boost)/lib" + APP_BIN="XPChain-Qt.app/Contents/MacOS/XPChain-Qt" + APP_FW_DIR="XPChain-Qt.app/Contents/Frameworks" + # macdeployqt may miss transitive non-Qt dylibs. Bundle all Boost dylibs and rewrite install names. + for libpath in "${BOOST_LIBDIR}"/libboost_*.dylib; do + [ -f "${libpath}" ] || continue + cp -f "${libpath}" "${APP_FW_DIR}/" + done + + for dylib in "${APP_FW_DIR}"/libboost_*.dylib; do + [ -f "${dylib}" ] || continue + base="$(basename "${dylib}")" + install_name_tool -id "@loader_path/${base}" "${dylib}" || true + otool -L "${dylib}" | awk '/libboost_.*\\.dylib/{print $1}' | while read -r dep; do + [ -n "${dep}" ] || continue + dep_base="$(basename "${dep}")" + install_name_tool -change "${dep}" "@loader_path/${dep_base}" "${dylib}" || true + done + done + + otool -L "${APP_BIN}" | awk '/libboost_.*\\.dylib/{print $1}' | while read -r dep; do + [ -n "${dep}" ] || continue + dep_base="$(basename "${dep}")" + install_name_tool -change "${dep}" "@executable_path/../Frameworks/${dep_base}" "${APP_BIN}" || true + done + # Re-sign after deployment to avoid broken signature state on user machines. + codesign --force --deep --sign - --timestamp=none XPChain-Qt.app + codesign --verify --deep --strict --verbose=2 XPChain-Qt.app + mkdir -p dmg-src + ditto XPChain-Qt.app dmg-src/XPChain-Qt.app + ln -s /Applications dmg-src/Applications + create-dmg \ + --volname "XPChain-Qt" \ + --window-pos 200 120 \ + --window-size 560 360 \ + --icon-size 120 \ + --icon "XPChain-Qt.app" 140 170 \ + --icon "Applications" 420 170 \ + --hide-extension "XPChain-Qt.app" \ + --app-drop-link 420 170 \ + "xpchain-${TAG}-macos.dmg" \ + "dmg-src" + tar -C dist -czf "xpchain-${TAG}-macos.tar.gz" xpchaind xpchain-cli xpchain-tx xpchain-qt + else + tar -C dist -czf "xpchain-${TAG}-macos.tar.gz" xpchaind xpchain-cli xpchain-tx + fi + + - name: Upload artifact + uses: actions/upload-artifact@v4 + with: + name: macos + path: | + xpchain-*-macos.tar.gz + xpchain-*-macos.dmg + + release: + name: Publish GitHub Release + runs-on: ubuntu-22.04 + needs: [linux, windows64, windows32] + steps: + - name: Download build artifacts + uses: actions/download-artifact@v4 + with: + path: release-assets + + - name: Flatten assets + run: | + mkdir -p out + find release-assets -type f \( -name '*.zip' -o -name '*.tar.gz' -o -name '*.dmg' \) -exec cp {} out/ \; + ls -lah out + + - name: Create release + uses: softprops/action-gh-release@v2 + with: + tag_name: ${{ env.RELEASE_TAG }} + name: XPChain Core ${{ env.RELEASE_TAG }} + generate_release_notes: true + files: out/* diff --git a/README.md b/README.md index 048fc55c41de..ce674a6b7717 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@ XPChain Core integration/staging tree [![Build Status](https://travis-ci.org/xpc-wg/xpchain.svg?branch=master)](https://travis-ci.org/xpc-wg/xpchain) -https://www.xpchain.io/ +https://www.xpchain.co.kr/ What is XPChain? ---------------- @@ -18,7 +18,7 @@ XPChain Core is the name of open source software which enables the use of this currency. For more information, read the [original whitepaper](https://www.xpchain.io/?loc=lnkwhitepaper). +the XPChain Core software, see https://bitcoincore.org/en/download/, --> read the [original whitepaper](https://www.xpchain.co.kr/?loc=lnkwhitepaper). For Exchanges ------- diff --git a/build-aux/m4/ax_boost_system.m4 b/build-aux/m4/ax_boost_system.m4 index 1c05450cbe1d..1476a0189fa5 100644 --- a/build-aux/m4/ax_boost_system.m4 +++ b/build-aux/m4/ax_boost_system.m4 @@ -109,11 +109,19 @@ AC_DEFUN([AX_BOOST_SYSTEM], fi if test "x$ax_lib" = "x"; then - AC_MSG_ERROR(Could not find a version of the boost_system library!) + dnl Boost.System can be header-only in newer Boost versions. + dnl If no library is found, continue without -lboost_system. + AC_MSG_WARN([Could not find a version of the boost_system library; continuing without it]) + BOOST_SYSTEM_LIB="" + AC_SUBST(BOOST_SYSTEM_LIB) + link_system="yes" + fi + if test "x$link_system" = "xno"; then + AC_MSG_WARN([Could not link against $ax_lib; continuing without boost_system library]) + BOOST_SYSTEM_LIB="" + AC_SUBST(BOOST_SYSTEM_LIB) + link_system="yes" fi - if test "x$link_system" = "xno"; then - AC_MSG_ERROR(Could not link against $ax_lib !) - fi fi CPPFLAGS="$CPPFLAGS_SAVED" diff --git a/configure.ac b/configure.ac index 884030b6bd3f..082bd4420130 100644 --- a/configure.ac +++ b/configure.ac @@ -3,12 +3,12 @@ AC_PREREQ([2.60]) define(_CLIENT_VERSION_MAJOR, 0) define(_CLIENT_VERSION_MINOR, 17) define(_CLIENT_VERSION_REVISION, 0) -define(_CLIENT_VERSION_BUILD, 3) +define(_CLIENT_VERSION_BUILD, 4) define(_CLIENT_VERSION_IS_RELEASE, true) -define(_COPYRIGHT_YEAR, 2019) +define(_COPYRIGHT_YEAR, 2026) define(_COPYRIGHT_HOLDERS,[The %s developers]) -define(_COPYRIGHT_HOLDERS_SUBSTITUTION,[[XPChain Core]]) -AC_INIT([XPChain Core],[_CLIENT_VERSION_MAJOR._CLIENT_VERSION_MINOR._CLIENT_VERSION_REVISION],[https://github.com/xpchain/xpchain/issues],[xpchain],[https://xpchaincore.org/]) +define(_COPYRIGHT_HOLDERS_SUBSTITUTION,[[XPChain Community]]) +AC_INIT([XPChain Core],[_CLIENT_VERSION_MAJOR._CLIENT_VERSION_MINOR._CLIENT_VERSION_REVISION],[https://github.com/arnoldcho/xpchain-community-core/issues],[xpchain],[https://www.xpchain.co.kr/]) AC_CONFIG_SRCDIR([src/validation.cpp]) AC_CONFIG_HEADERS([src/config/bitcoin-config.h]) AC_CONFIG_AUX_DIR([build-aux]) diff --git a/depends/packages/boost.mk b/depends/packages/boost.mk index 61806c7509ef..e0e6d711899d 100644 --- a/depends/packages/boost.mk +++ b/depends/packages/boost.mk @@ -1,6 +1,6 @@ package=boost $(package)_version=1_64_0 -$(package)_download_path=https://dl.bintray.com/boostorg/release/1.64.0/source/ +$(package)_download_path=https://archives.boost.io/release/1.64.0/source/ $(package)_file_name=$(package)_$($(package)_version).tar.bz2 $(package)_sha256_hash=7bcc5caace97baa948931d712ea5f37038dbb1c5d89b43ad4def4ed7cb683332 diff --git a/depends/packages/qt.mk b/depends/packages/qt.mk index 65ecadb43b52..8b16f61fc200 100644 --- a/depends/packages/qt.mk +++ b/depends/packages/qt.mk @@ -1,6 +1,6 @@ PACKAGE=qt $(package)_version=5.9.6 -$(package)_download_path=https://download.qt.io/official_releases/qt/5.9/$($(package)_version)/submodules +$(package)_download_path=https://download.qt.io/new_archive/qt/5.9/$($(package)_version)/submodules $(package)_suffix=opensource-src-$($(package)_version).tar.xz $(package)_file_name=qtbase-$($(package)_suffix) $(package)_sha256_hash=eed620cb268b199bd83b3fc6a471c51d51e1dc2dbb5374fc97a0cc75facbe36f @@ -122,6 +122,8 @@ define $(package)_preprocess_cmds sed -i.old "s|updateqm.commands = \$$$$\$$$$LRELEASE|updateqm.commands = $($(package)_extract_dir)/qttools/bin/lrelease|" qttranslations/translations/translations.pro && \ sed -i.old "/updateqm.depends =/d" qttranslations/translations/translations.pro && \ sed -i.old "s/src_plugins.depends = src_sql src_network/src_plugins.depends = src_network/" qtbase/src/src.pro && \ + sed -i.old '/#include /a\ +\#include ' qtbase/src/corelib/tools/qbytearraymatcher.h && \ sed -i.old "s|X11/extensions/XIproto.h|X11/X.h|" qtbase/src/plugins/platforms/xcb/qxcbxsettings.cpp && \ sed -i.old 's/if \[ "$$$$XPLATFORM_MAC" = "yes" \]; then xspecvals=$$$$(macSDKify/if \[ "$$$$BUILD_ON_MAC" = "yes" \]; then xspecvals=$$$$(macSDKify/' qtbase/configure && \ sed -i.old 's/CGEventCreateMouseEvent(0, kCGEventMouseMoved, pos, 0)/CGEventCreateMouseEvent(0, kCGEventMouseMoved, pos, kCGMouseButtonLeft)/' qtbase/src/plugins/platforms/cocoa/qcocoacursor.mm && \ diff --git a/doc/README.md b/doc/README.md index 3641ca888f06..270ecf6afb59 100644 --- a/doc/README.md +++ b/doc/README.md @@ -5,7 +5,7 @@ Setup --------------------- XPChain Core is the original XPChain client and it builds the backbone of the network. It downloads and, by default, stores the entire history of XPChain transactions (which is currently more than 100 GBs); depending on the speed of your computer and network connection, the synchronization process can take anywhere from a few hours to a day or more. -To download XPChain Core, visit the [official website](https://www.xpchain.io/). +To download XPChain Core, visit the [official website](https://www.xpchain.co.kr/). Running --------------------- diff --git a/doc/linux-node-setup-log-vultr.md b/doc/linux-node-setup-log-vultr.md new file mode 100644 index 000000000000..b58ddf8badd7 --- /dev/null +++ b/doc/linux-node-setup-log-vultr.md @@ -0,0 +1,202 @@ +# Vultr Node Setup Log + +## 2026-02-24 - Initial Instance Provisioning + +### Purpose +- XPChain wallet/node installation test on Ubuntu desktop environment + +### Provider / Plan +- Provider: Vultr +- Plan: Shared CPU `$10/mo` +- Size: `vc2-1c-2gb` +- vCPU: `1` +- Memory: `2 GB` +- Storage: `55 GB` + +### Region / Image +- Region: `Singapore, SG` +- Marketplace App: `Ubuntu Desktop (XFCE)` +- OS: `Ubuntu 24.04` +- Marketplace variable `desktopuser`: `arnold` + +### Server Identity +- Hostname: `XPChain-Node-05` +- Label: `XPChain-Node-05` + +### Connectivity +- Instance connectivity: `Instance(s) with Public IP` +- Public IPv4: `Enabled` +- Public IPv6: `Not selected` + +### Additional Features +- VPC Network: `Disabled` +- Automatic Backups: `Disabled` +- DDoS Protection: `Disabled` +- Limited User Login: `Not enabled in this screen` +- Cloud-Init User Data: `Disabled` + +### Pending +- [ ] Deploy instance +- [ ] SSH access verification +- [ ] XPChain binaries install +- [ ] xpchaind first run and sync check +- [ ] Firewall / systemd setup +- [ ] Installation guide update for website + +## Linux Install Procedure (v0.17.0-4) + +### Release source +- Tag: `v0.17.0-4` +- Download URL: + - `https://github.com/arnoldcho/xpchain-community-core/releases/download/v0.17.0-4/xpchain-v0.17.0-4-linux-x86_64.tar.gz` + +### Installation commands +```bash +mkdir -p ~/xpchain && cd ~/xpchain +wget -O xpchain-v0.17.0-4-linux-x86_64.tar.gz \ +https://github.com/arnoldcho/xpchain-community-core/releases/download/v0.17.0-4/xpchain-v0.17.0-4-linux-x86_64.tar.gz +tar -xzf xpchain-v0.17.0-4-linux-x86_64.tar.gz +chmod +x xpchaind xpchain-cli xpchain-tx xpchain-qt +``` + +### Archive structure note +- `xpchain-v0.17.0-4-linux-x86_64.tar.gz` extracts binaries directly into current directory. +- No subdirectory is created after extraction. + +### Initial node config +```bash +mkdir -p ~/.xpchain +cat > ~/.xpchain/xpchain.conf << 'EOF' +server=1 +listen=1 +port=8798 +bind=0.0.0.0 +discover=1 +dnsseed=1 +maxconnections=64 +fallbackfee=0.11 +EOF +``` + +### Fee fallback option +- If fee estimation is unstable right after startup/sync, set a fallback fee. +- Recommended: put it in `xpchain.conf` so both daemon and wallet use it consistently. +- Temporary CLI/GUI launch examples: +```bash +./xpchaind -fallbackfee=0.11 +./xpchain-qt -fallbackfee=0.11 +``` + +### Start and verify +```bash +./xpchaind -daemon +./xpchain-cli getblockchaininfo +./xpchain-cli getnetworkinfo +./xpchain-cli getconnectioncount +``` + +### Qt launch (desktop environment) +```bash +./xpchain-qt +``` + +### Firewall +```bash +sudo ufw allow 8798/tcp +sudo ufw status +``` + +### Notes +- This section is a baseline procedure and will be updated if runtime/install issues are found. + +## Troubleshooting + +### `./xpchaind: error while loading shared libraries: libboost_filesystem.so.1.74.0` + +Cause: +- Current Linux release artifact was built on Ubuntu 22.04 toolchain and linked against Boost `1.74`. +- Ubuntu 24.04 default Boost runtime is newer, so `libboost_filesystem.so.1.74.0` may not exist. + +Current guidance: +1. Preferred for immediate test: + - Use Ubuntu `22.04` server image for runtime compatibility with current artifact. +2. Preferred long-term release fix: + - Rebuild Linux artifact targeting Ubuntu `24.04` (or package with portable/static strategy). +3. Quick diagnostics command: +```bash +ldd ./xpchaind | grep -E 'not found|boost' +``` + +## Validation Result (2026-02-24) + +### Runtime status +- `xpchaind` startup: `OK` +- `xpchain-cli getblockchaininfo`: `OK` +- `xpchain-cli getnetworkinfo`: `OK` +- `xpchain-cli getconnectioncount`: `7` (at capture time) + +### Sync snapshot +- `chain`: `main` +- `blocks`: `3368` (sync in progress) +- `headers`: `424000` +- `initialblockdownload`: `true` + +### Notes +- Linux standalone (4-file) runtime test passed on current test server. +- Node is syncing and network connections are established. + +## Basic CLI Commands + +```bash +# 노드 기본 상태 +./xpchain-cli getblockchaininfo +./xpchain-cli getnetworkinfo +./xpchain-cli getconnectioncount + +# 지갑 상태 +./xpchain-cli getwalletinfo +./xpchain-cli getbalances + +# 블록/트랜잭션 조회 +./xpchain-cli getbestblockhash +./xpchain-cli getblockcount +./xpchain-cli getblockhash +./xpchain-cli getblock +./xpchain-cli getrawtransaction 1 + +# 주소/입출금 +./xpchain-cli getnewaddress +./xpchain-cli getreceivedbyaddress
+./xpchain-cli sendtoaddress
+``` + +## Incident Response Commands + +```bash +# 프로세스 확인 +ps -ef | grep xpchaind | grep -v grep +pgrep -a xpchaind + +# 서비스 사용 시 상태/로그 +sudo systemctl status xpchaind --no-pager +journalctl -u xpchaind -n 100 --no-pager +journalctl -u xpchaind -f + +# 데몬 직접 실행 시 로그 +tail -n 100 ~/.xpchain/debug.log +tail -f ~/.xpchain/debug.log + +# 피어/네트워크 진단 +./xpchain-cli getpeerinfo | grep -E '"addr"|"inbound"' +./xpchain-cli getconnectioncount +ss -lntp | grep 8798 +sudo ufw status verbose + +# 블록 동기화 진단 +./xpchain-cli getblockchaininfo +./xpchain-cli getchaintips + +# 정지/시작 +./xpchain-cli stop +./xpchaind -daemon +``` diff --git a/doc/man/xpchain-cli.1 b/doc/man/xpchain-cli.1 index 6b3435c97eb2..5884eddd4b7c 100644 --- a/doc/man/xpchain-cli.1 +++ b/doc/man/xpchain-cli.1 @@ -105,7 +105,7 @@ Copyright (C) 2018-2019 The XPChain Core developers Copyright (C) 2009-2019 The Bitcoin Core developers Please contribute if you find XPChain Core useful. Visit - for further information about the software. + for further information about the software. The source code is available from . This is experimental software. diff --git a/doc/man/xpchain-qt.1 b/doc/man/xpchain-qt.1 index 33bad8f74795..37ce73a95bbb 100644 --- a/doc/man/xpchain-qt.1 +++ b/doc/man/xpchain-qt.1 @@ -613,7 +613,7 @@ Copyright (C) 2018-2019 The XPChain Core developers Copyright (C) 2009-2019 The Bitcoin Core developers Please contribute if you find XPChain Core useful. Visit - for further information about the software. + for further information about the software. The source code is available from . This is experimental software. diff --git a/doc/man/xpchain-tx.1 b/doc/man/xpchain-tx.1 index 5c25ec859e20..0213aa327e07 100644 --- a/doc/man/xpchain-tx.1 +++ b/doc/man/xpchain-tx.1 @@ -109,7 +109,7 @@ Copyright (C) 2018-2019 The XPChain Core developers Copyright (C) 2009-2019 The Bitcoin Core developers Please contribute if you find XPChain Core useful. Visit - for further information about the software. + for further information about the software. The source code is available from . This is experimental software. diff --git a/doc/man/xpchaind.1 b/doc/man/xpchaind.1 index 7f2358e0374b..145a52f85008 100644 --- a/doc/man/xpchaind.1 +++ b/doc/man/xpchaind.1 @@ -587,7 +587,7 @@ Copyright (C) 2018-2019 The XPChain Core developers Copyright (C) 2009-2019 The Bitcoin Core developers Please contribute if you find XPChain Core useful. Visit - for further information about the software. + for further information about the software. The source code is available from . This is experimental software. diff --git a/doc/release-github-actions.md b/doc/release-github-actions.md new file mode 100644 index 000000000000..f518a1e4eaf0 --- /dev/null +++ b/doc/release-github-actions.md @@ -0,0 +1,37 @@ +# XPChain Core 릴리즈 가이드 (GitHub Actions) + +이 저장소(`arnoldcho/xpchain-community-core`)는 태그 기준으로 자동 빌드/릴리즈하도록 설정되어 있습니다. + +## 1) 지원 대상 +- Linux (Ubuntu x86_64): `xpchaind`, `xpchain-cli`, `xpchain-tx`, `xpchain-qt` +- Windows 64bit: `xpchaind.exe`, `xpchain-cli.exe`, `xpchain-tx.exe`, `xpchain-qt.exe` +- Windows 32bit: `xpchaind.exe`, `xpchain-cli.exe`, `xpchain-tx.exe`, `xpchain-qt.exe` +- macOS: `xpchaind`, `xpchain-cli`, `xpchain-tx`, `xpchain-qt` + +주의: iOS는 XPChain Core(데스크톱/노드 소프트웨어) 공식 빌드 타깃이 아닙니다. + +## 2) 릴리즈 실행 방법 + +### 방법 A. 태그 푸시 (권장) +```bash +git tag v0.17.0-4 +git push origin v0.17.0-4 +``` + +### 방법 B. 수동 실행 +- GitHub 저장소 > Actions > `Build and Release XPChain Core` +- `Run workflow` 클릭 +- `tag` 입력 (예: `v0.17.0-4`) + +## 3) 결과물 확인 +- GitHub Releases에 자동 생성 +- 첨부 파일 예시: + - `xpchain-v0.17.0-4-linux-x86_64.tar.gz` + - `xpchain-v0.17.0-4-win64.zip` + - `xpchain-v0.17.0-4-win32.zip` + - `xpchain-v0.17.0-4-macos.tar.gz` + +## 4) 운영 권장사항 +- 태그를 찍기 전에 `master` 기준으로 테스트 빌드 1회 권장 +- 릴리즈 노트에 변경점(합의/지갑/네트워크)을 꼭 명시 +- 파일 해시(`sha256sum`)를 릴리즈 노트에 함께 게시 diff --git a/doc/release-notes.md b/doc/release-notes.md index d41fdb16ece9..3bf43495a691 100644 --- a/doc/release-notes.md +++ b/doc/release-notes.md @@ -3,7 +3,7 @@ release-notes at release time) XPChain Core version *version* is now available from: - + This is a new minor version release, including various bugfixes and performance improvements. diff --git a/doc/release-process.md b/doc/release-process.md index ac3dacd82055..c3b68490cfe4 100644 --- a/doc/release-process.md +++ b/doc/release-process.md @@ -27,7 +27,7 @@ Before every major release: Finally: * Announce the release: - - Update xpchain.io + - Update xpchain.co.kr - Official announcements in Discord, Twitter, etc. - Archive release notes for the new version to `doc/release-notes/` (branch `master` and branch of the release) - Create a [new GitHub release](https://github.com/xpc-wg/xpchain/releases/new) with a link to the archived release notes. diff --git a/doc/release-validation-v0.17.0-4.md b/doc/release-validation-v0.17.0-4.md new file mode 100644 index 000000000000..0a0f22f53b90 --- /dev/null +++ b/doc/release-validation-v0.17.0-4.md @@ -0,0 +1,178 @@ +# XPChain Core v0.17.0-4 Release Validation + +## Scope +- Release tag: `v0.17.0-4` +- Repository: `arnoldcho/xpchain-community-core` +- Validation type: runtime smoke + wallet functional test + +## macOS Validation (PASS) + +### Environment +- Platform: macOS (Apple Silicon) +- App: `XPChain-Qt.app` +- Build: `0.17.0` + +### Checks +1. App launch +- Result: `PASS` +- Notes: App launches and console/debug window is accessible. + +2. Sync state +- Result: `PASS` +- Notes: Node sync completed and wallet entered normal operating state. + +3. Wallet info RPC +- Command: `getwalletinfo` +- Result: `PASS` +- Notes: wallet fields returned normally (`walletversion`, `balance`, keypool, hdseed). + +4. Receive transaction flow +- Command: `listtransactions` +- Result: `PASS` +- Notes: `category: "receive"` entry confirmed with confirmations increasing. + +5. Send transaction flow +- Command: `listtransactions` +- Result: `PASS` +- Notes: `category: "send"` entry confirmed with fee applied and confirmation progress. + +### Conclusion +- macOS runtime and wallet send/receive behavior validated for `v0.17.0-4`. +- Current status: **usable for practical wallet operation** under tested environment. + +## Follow-up +- Keep using `rc` tags for pre-release validation and only finalize stable version tags after runtime checks on all target OS. + +## Linux Validation (PASS) + +### Environment +- Platform: Ubuntu 24.04 (Vultr, XFCE) +- Binary package: `xpchain-v0.17.0-4-linux-x86_64.tar.gz` +- Runtime files: `xpchaind`, `xpchain-cli`, `xpchain-tx`, `xpchain-qt` + +### Checks +1. Node start and chain progress +- Command: `./xpchain-cli getblockchaininfo` +- Result: `PASS` +- Notes: node started normally, chain sync progressed from low height and continued. + +2. P2P connectivity +- Command: `./xpchain-cli getnetworkinfo`, `./xpchain-cli getconnectioncount` +- Result: `PASS` +- Notes: active peers observed (`connections` in normal range, e.g. 7~9). + +3. Wallet status RPC +- Command: `./xpchain-cli getwalletinfo` +- Result: `PASS` +- Notes: wallet metadata and keypool fields returned normally. + +4. Receive transaction flow +- Command: `listtransactions` (Qt debug console) +- Result: `PASS` +- Notes: `category: "receive"` transaction confirmed, confirmations increased over time. + +5. Send transaction flow +- Command: `listtransactions` (Qt debug console) +- Result: `PASS` +- Notes: `category: "send"` transaction confirmed with fee and block inclusion. + +6. Restart resilience +- Action: `xpchaind` / `xpchain-qt` stop-start cycle +- Result: `PASS` +- Notes: wallet and node resumed normally after restart. + +### Conclusion +- Linux runtime and wallet receive/send/restart behavior validated for `v0.17.0-4`. +- Current status: **usable for practical wallet operation** under tested Ubuntu 24.04 environment. + +## Windows Validation (PASS) + +### Environment +- Platform: Windows 64-bit +- Runtime binary: `xpchain-qt.exe` +- Build: `0.17.0` + +### Checks +1. App launch +- Result: `PASS` +- Notes: `xpchain-qt.exe` launched normally on Windows 64-bit environment. + +2. Node start and chain progress +- Command: `./xpchain-cli getblockchaininfo` +- Result: `PASS` +- Notes: node started normally, chain sync progressed from low height and continued. + +3. P2P connectivity +- Command: `./xpchain-cli getnetworkinfo`, `./xpchain-cli getconnectioncount` +- Result: `PASS` +- Notes: active peers observed (`connections` in normal range, e.g. 7~9). + +4. Wallet status RPC +- Command: `./xpchain-cli getwalletinfo` +- Result: `PASS` +- Notes: wallet metadata and keypool fields returned normally. + +5. Receive transaction flow +- Command: `listtransactions` (Qt debug console) +- Result: `PASS` +- Notes: `category: "receive"` transaction confirmed, confirmations increased over time. + +6. Send transaction flow +- Command: `listtransactions` (Qt debug console) +- Result: `PASS` +- Notes: `category: "send"` transaction confirmed with fee and block inclusion. + +7. Restart resilience +- Action: close and relaunch wallet (`xpchain-qt.exe`) +- Result: `PASS` +- Notes: wallet restarted cleanly and returned to normal state after relaunch. + +### Conclusion +- Windows 64-bit runtime and wallet receive/send/restart behavior validated for `v0.17.0-4`. +- Current status: **usable for practical wallet operation** under tested Windows 64-bit environment. + +## Windows 32-bit Validation (PASS) + +### Environment +- Platform: Windows 32-bit +- Runtime binary: `xpchain-qt.exe` +- Build: `0.17.0` + +### Checks +1. App launch +- Result: `PASS` +- Notes: `xpchain-qt.exe` launched normally on Windows 32-bit environment. + +2. Node start and chain progress +- Command: `./xpchain-cli getblockchaininfo` +- Result: `PASS` +- Notes: node started normally, chain sync progressed from low height and continued. + +3. P2P connectivity +- Command: `./xpchain-cli getnetworkinfo`, `./xpchain-cli getconnectioncount` +- Result: `PASS` +- Notes: active peers observed (`connections` in normal range, e.g. 7~9). + +4. Wallet status RPC +- Command: `./xpchain-cli getwalletinfo` +- Result: `PASS` +- Notes: wallet metadata and keypool fields returned normally. + +5. Receive transaction flow +- Command: `listtransactions` (Qt debug console) +- Result: `PASS` +- Notes: `category: "receive"` transaction confirmed, confirmations increased over time. + +6. Send transaction flow +- Command: `listtransactions` (Qt debug console) +- Result: `PASS` +- Notes: `category: "send"` transaction confirmed with fee and block inclusion. + +7. Restart resilience +- Action: close and relaunch wallet (`xpchain-qt.exe`) +- Result: `PASS` +- Notes: wallet restarted cleanly and returned to normal state after relaunch. + +### Conclusion +- Windows 32-bit runtime and wallet receive/send/restart behavior validated for `v0.17.0-4`. +- Current status: **usable for practical wallet operation** under tested Windows 32-bit environment. diff --git a/doc/xpchain-release-notes/xpchain-release-notes-0.17.0-2.md b/doc/xpchain-release-notes/xpchain-release-notes-0.17.0-2.md index 409f95402855..15ecbb2f5fd1 100644 --- a/doc/xpchain-release-notes/xpchain-release-notes-0.17.0-2.md +++ b/doc/xpchain-release-notes/xpchain-release-notes-0.17.0-2.md @@ -1,6 +1,6 @@ XPChain Core version 0.17.0-2 is now available from: - + This is a new minor version release, with various bugfixes and translation updates. diff --git a/doc/xpchain-release-notes/xpchain-release-notes-0.17.0-3.md b/doc/xpchain-release-notes/xpchain-release-notes-0.17.0-3.md index 600317576225..77f351f4e6d3 100644 --- a/doc/xpchain-release-notes/xpchain-release-notes-0.17.0-3.md +++ b/doc/xpchain-release-notes/xpchain-release-notes-0.17.0-3.md @@ -1,6 +1,6 @@ XPChain Core version 0.17.0-3 is now available from: - + This is a new minor version release, including various bugfixes and performance improvements. diff --git a/doc/xpchain-release-notes/xpchain-release-notes-0.17.0-4.md b/doc/xpchain-release-notes/xpchain-release-notes-0.17.0-4.md new file mode 100644 index 000000000000..fdb7a67485e6 --- /dev/null +++ b/doc/xpchain-release-notes/xpchain-release-notes-0.17.0-4.md @@ -0,0 +1,88 @@ +XPChain Core version 0.17.0-4 is now available: + + + +This is a maintenance and packaging release focused on build reliability, +multi-OS distribution, and operational documentation updates. + +This release does not include any consensus or protocol changes. +It is fully compatible with the current mainnet. + +Please report bugs using the issue tracker: + + + +How to Upgrade +============== + +If you are running an older version, shut it down and wait until it has +completely exited. Then install the binaries from this release and restart. + +Compatibility +============= + +XPChain Core 0.17.0-4 provides release artifacts for: + +- Linux x86_64 (tar.gz) +- macOS (dmg, tar.gz) +- Windows x86 / x64 (zip) + +Notable changes +=============== + +Release build and packaging +--------------------------- + +- Stabilized multi-OS GitHub Actions release workflow. +- Improved packaging outputs for Linux, Windows, and macOS. +- Added SHA-256 checksums for release integrity verification. + +macOS build and app packaging improvements +------------------------------------------ + +- Resolved modern toolchain compatibility issues. +- Improved DMG/app bundle creation flow. +- Enhanced macOS runtime dependency packaging. + +Windows/Linux compatibility fixes +--------------------------------- + +- Applied compatibility fixes for modern compilers and dependencies. +- Improved CI build reliability across platforms. + +Project metadata updates +------------------------ + +- Updated project links and metadata. +- Refreshed About/Splash text to reflect current community maintenance context. + +UI text and localization updates +-------------------------------- + +- Updated About dialog wording to: "This software is under active community + maintenance and may change between releases." +- Aligned Korean/Japanese translation keys with updated About text. +- Improved Korean wording quality for fee, pruning/reindex, and wallet error + messages to reduce ambiguity in user-facing dialogs. + +Operational documentation +------------------------- + +- Added Linux node setup guide and troubleshooting notes. +- Added practical CLI command examples and incident-response references. + +XPChain 0.17.0-4 change log +--------------------------- + +- Multi-OS release automation improvements +- Packaging and runtime dependency fixes +- macOS DMG/app bundle generation improvements +- Windows/Linux compatibility fixes +- About/Splash metadata update +- About wording and localization update (ko/ja) +- Linux node setup documentation + +Credits +======= + +Thanks to everyone who contributed to this release and verification process. diff --git a/src/chainparams.cpp b/src/chainparams.cpp index fe55bca65ffb..eccf05db123c 100644 --- a/src/chainparams.cpp +++ b/src/chainparams.cpp @@ -143,9 +143,9 @@ class CMainParams : public CChainParams { // This is fine at runtime as we'll fall back to using them as a oneshot if they don't support the // service bits we want, but we should get them updated to support all service bits wanted by any // release ASAP to avoid it where possible. - vSeeds.emplace_back("seed1.xpchain.io"); - vSeeds.emplace_back("seed2.xpchain.io"); - vSeeds.emplace_back("seed3.xpchain.io"); + vSeeds.emplace_back("seed1.xpchain.co.kr"); + vSeeds.emplace_back("seed2.xpchain.co.kr"); + vSeeds.emplace_back("seed3.xpchain.co.kr"); base58Prefixes[PUBKEY_ADDRESS] = std::vector(1,76); base58Prefixes[SCRIPT_ADDRESS] = std::vector(1,28); @@ -249,9 +249,9 @@ class CTestNetParams : public CChainParams { vFixedSeeds.clear(); vSeeds.clear(); // nodes with support for servicebits filtering should be at the top - vSeeds.emplace_back("seed1.xpchain.io"); - vSeeds.emplace_back("seed2.xpchain.io"); - vSeeds.emplace_back("seed3.xpchain.io"); + vSeeds.emplace_back("seed1.xpchain.co.kr"); + vSeeds.emplace_back("seed2.xpchain.co.kr"); + vSeeds.emplace_back("seed3.xpchain.co.kr"); base58Prefixes[PUBKEY_ADDRESS] = std::vector(1,138); base58Prefixes[SCRIPT_ADDRESS] = std::vector(1,88); diff --git a/src/dbwrapper.cpp b/src/dbwrapper.cpp index f5fb71580004..e0e55dcefe2c 100644 --- a/src/dbwrapper.cpp +++ b/src/dbwrapper.cpp @@ -115,7 +115,7 @@ static leveldb::Options GetOptions(size_t nCacheSize) } CDBWrapper::CDBWrapper(const fs::path& path, size_t nCacheSize, bool fMemory, bool fWipe, bool obfuscate) - : m_name(fs::basename(path)) + : m_name(path.filename().string()) { penv = nullptr; readoptions.verify_checksums = true; diff --git a/src/httpserver.cpp b/src/httpserver.cpp index d722adee152a..854a9c7384c4 100644 --- a/src/httpserver.cpp +++ b/src/httpserver.cpp @@ -14,6 +14,7 @@ #include #include +#include #include #include #include diff --git a/src/init.cpp b/src/init.cpp index d1ed7ef960c1..0000da7dab25 100644 --- a/src/init.cpp +++ b/src/init.cpp @@ -529,20 +529,22 @@ void SetupServerArgs() std::string LicenseInfo() { - const std::string URL_SOURCE_CODE = ""; - const std::string URL_WEBSITE = ""; + const std::string URL_SOURCE_CODE = ""; + const std::string URL_WEBSITE = ""; + const std::string COPYRIGHT_XPCHAIN_COMMUNITY = "Copyright (C) 2019-2026 The XPChain Community developers"; + const std::string COPYRIGHT_XPCHAIN_CORE = "Copyright (C) 2018-2019 The XPChain Core developers"; - return CopyrightHolders(strprintf(_("Copyright (C) %i-%i"), 2018, COPYRIGHT_YEAR) + " ") + "\n" + + return COPYRIGHT_XPCHAIN_COMMUNITY + "\n" + + COPYRIGHT_XPCHAIN_CORE + "\n" + "\n" + - strprintf(_("Please contribute if you find %s useful. " - "Visit %s for further information about the software."), + strprintf(_("For the latest information about %s, visit %s."), PACKAGE_NAME, URL_WEBSITE) + "\n" + strprintf(_("The source code is available from %s."), URL_SOURCE_CODE) + "\n" + "\n" + - _("This is experimental software.") + "\n" + + _("This software is under active community maintenance and may change between releases.") + "\n" + strprintf(_("Distributed under the MIT software license, see the accompanying file %s or %s"), "COPYING", "") + "\n" + "\n" + strprintf(_("This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit %s and cryptographic software written by Eric Young and UPnP software written by Thomas Bernard."), "") + diff --git a/src/qt/bitcoingui.cpp b/src/qt/bitcoingui.cpp index 606272f88ee0..7634ef0a80b3 100644 --- a/src/qt/bitcoingui.cpp +++ b/src/qt/bitcoingui.cpp @@ -1253,8 +1253,8 @@ static bool ThreadSafeMessageBox(BitcoinGUI *gui, const std::string& message, co void BitcoinGUI::subscribeToCoreSignals() { // Connect signals to client - m_handler_message_box = m_node.handleMessageBox(boost::bind(ThreadSafeMessageBox, this, _1, _2, _3)); - m_handler_question = m_node.handleQuestion(boost::bind(ThreadSafeMessageBox, this, _1, _3, _4)); + m_handler_message_box = m_node.handleMessageBox(boost::bind(ThreadSafeMessageBox, this, boost::placeholders::_1, boost::placeholders::_2, boost::placeholders::_3)); + m_handler_question = m_node.handleQuestion(boost::bind(ThreadSafeMessageBox, this, boost::placeholders::_1, boost::placeholders::_3, boost::placeholders::_4)); } void BitcoinGUI::unsubscribeFromCoreSignals() diff --git a/src/qt/clientmodel.cpp b/src/qt/clientmodel.cpp index 7154ac14be63..c40a6703a738 100644 --- a/src/qt/clientmodel.cpp +++ b/src/qt/clientmodel.cpp @@ -247,13 +247,13 @@ static void BlockTipChanged(ClientModel *clientmodel, bool initialSync, int heig void ClientModel::subscribeToCoreSignals() { // Connect signals to client - m_handler_show_progress = m_node.handleShowProgress(boost::bind(ShowProgress, this, _1, _2)); - m_handler_notify_num_connections_changed = m_node.handleNotifyNumConnectionsChanged(boost::bind(NotifyNumConnectionsChanged, this, _1)); - m_handler_notify_network_active_changed = m_node.handleNotifyNetworkActiveChanged(boost::bind(NotifyNetworkActiveChanged, this, _1)); + m_handler_show_progress = m_node.handleShowProgress(boost::bind(ShowProgress, this, boost::placeholders::_1, boost::placeholders::_2)); + m_handler_notify_num_connections_changed = m_node.handleNotifyNumConnectionsChanged(boost::bind(NotifyNumConnectionsChanged, this, boost::placeholders::_1)); + m_handler_notify_network_active_changed = m_node.handleNotifyNetworkActiveChanged(boost::bind(NotifyNetworkActiveChanged, this, boost::placeholders::_1)); m_handler_notify_alert_changed = m_node.handleNotifyAlertChanged(boost::bind(NotifyAlertChanged, this)); m_handler_banned_list_changed = m_node.handleBannedListChanged(boost::bind(BannedListChanged, this)); - m_handler_notify_block_tip = m_node.handleNotifyBlockTip(boost::bind(BlockTipChanged, this, _1, _2, _3, _4, false)); - m_handler_notify_header_tip = m_node.handleNotifyHeaderTip(boost::bind(BlockTipChanged, this, _1, _2, _3, _4, true)); + m_handler_notify_block_tip = m_node.handleNotifyBlockTip(boost::bind(BlockTipChanged, this, boost::placeholders::_1, boost::placeholders::_2, boost::placeholders::_3, boost::placeholders::_4, false)); + m_handler_notify_header_tip = m_node.handleNotifyHeaderTip(boost::bind(BlockTipChanged, this, boost::placeholders::_1, boost::placeholders::_2, boost::placeholders::_3, boost::placeholders::_4, true)); } void ClientModel::unsubscribeFromCoreSignals() diff --git a/src/qt/locale/bitcoin_ja.ts b/src/qt/locale/bitcoin_ja.ts index ba2a9cf66901..2a49d6d1e072 100644 --- a/src/qt/locale/bitcoin_ja.ts +++ b/src/qt/locale/bitcoin_ja.ts @@ -3839,8 +3839,8 @@ Note: Since the fee is calculated on a per-byte basis, a fee of "100 mocha 取引の金額が小さすぎて手数料を支払えません - This is experimental software. - これは実験用のソフトウェアです。 + This software is under active community maintenance and may change between releases. + このソフトウェアはコミュニティによって継続的に保守されており、リリース間で変更される場合があります。 Transaction amount too small diff --git a/src/qt/locale/bitcoin_ko_KR.ts b/src/qt/locale/bitcoin_ko_KR.ts index f89cd5eb946f..9e54ffce0213 100644 --- a/src/qt/locale/bitcoin_ko_KR.ts +++ b/src/qt/locale/bitcoin_ko_KR.ts @@ -2377,7 +2377,7 @@ Using the fallbackfee can result in sending a transaction that will take several hours or days (or never) to confirm. Consider choosing your fee manually or wait until you have validated the complete chain. - Fallbackfee를 사용하게 될 경우 보낸 거래가 승인이 완료 될 때까지 몇 시간 혹은 몇 일 (혹은 영원히) 이 걸릴 수 있습니다. 수동으로 수수료를 선택하거나 전체 체인의 유효성이 검증될 때까지 기다리십시오. + -fallbackfee 사용 시 거래 확인이 수시간~수일 지연되거나 확인되지 않을 수 있습니다. 수수료를 수동으로 지정하거나 체인 검증이 완료될 때까지 기다리십시오. Warning: Fee estimation is currently not possible. @@ -2421,7 +2421,7 @@ Note: Since the fee is calculated on a per-byte basis, a fee of "100 mocha (Smart fee not initialized yet. This usually takes a few blocks...) - (Smart fee가 아직 초기화 되지 않았습니다. 블록 분석이 완전하게 끝날 때 까지 기다려주십시오...) + (스마트 수수료가 아직 초기화되지 않았습니다. 보통 몇 개 블록이 더 필요합니다...) Send to multiple recipients at once @@ -3508,11 +3508,11 @@ Note: Since the fee is calculated on a per-byte basis, a fee of "100 mocha Prune: last wallet synchronisation goes beyond pruned data. You need to -reindex (download the whole blockchain again in case of pruned node) - 블록 축소: 마지막 지갑 동기화 지점이 축소된 데이터보다 과거의 것 입니다. -reindex가 필요합니다 (정지된 노드의 경우 모든 블록체인을 재다운로드합니다) + 프루닝: 마지막 지갑 동기화 지점이 프루닝된 데이터 범위를 벗어났습니다. -reindex가 필요합니다 (프루닝 노드에서는 전체 블록체인을 다시 다운로드합니다) Rescans are not possible in pruned mode. You will need to use -reindex which will download the whole blockchain again. - 블록 축소 모드에서는 재검색이 불가능 합니다. -reindex 명령을 사용해서 모든 블록체인을 다시 다운로드 해야 합니다. + 프루닝 모드에서는 재검색이 지원되지 않습니다. -reindex를 사용해 전체 블록체인을 다시 다운로드해야 합니다. Error: A fatal internal error occurred, see debug.log for details @@ -3551,8 +3551,8 @@ Note: Since the fee is calculated on a per-byte basis, a fee of "100 mocha 컴퓨터의 날짜와 시간이 올바른지 확인하십시오! 시간이 잘못되면 %s은 제대로 동작하지 않습니다. - Please contribute if you find %s useful. Visit %s for further information about the software. - %s가 유용하다고 생각한다면 프로젝트에 공헌해주세요. 이 소프트웨어에 대한 보다 자세한 정보는 %s를 방문해주십시오. + For the latest information about %s, visit %s. + %s의 최신 정보는 %s에서 확인하십시오. The block database contains a block which appears to be from the future. This may be due to your computer's date and time being set incorrectly. Only rebuild the block database if you are sure that your computer's date and time are correct @@ -3680,7 +3680,7 @@ Note: Since the fee is calculated on a per-byte basis, a fee of "100 mocha Invalid amount for -discardfee=<amount>: '%s' - -discardfee=<amount>에 대한 양이 잘못되었습니다: '%s' + -discardfee=<amount> 값이 올바르지 않습니다: '%s' Invalid amount for -fallbackfee=<amount>: '%s' @@ -3776,7 +3776,7 @@ Note: Since the fee is calculated on a per-byte basis, a fee of "100 mocha Invalid amount for -maxtxfee=<amount>: '%s' (must be at least the minrelay fee of %s to prevent stuck transactions) - 유효하지 않은 금액 -maxtxfee=<amount>: '%s' (거래가 막히는 상황을 방지하게 위해 적어도 %s 의 중계 수수료를 지정해야 합니다) + 유효하지 않은 금액 -maxtxfee=<amount>: '%s' (거래가 멈추는 상황을 방지하기 위해 최소 %s의 중계 수수료를 지정해야 합니다) The transaction amount is too small to send after the fee has been deducted @@ -3784,7 +3784,7 @@ Note: Since the fee is calculated on a per-byte basis, a fee of "100 mocha You need to rebuild the database using -reindex to go back to unpruned mode. This will redownload the entire blockchain - 축소 모드를 해제하고 데이터베이스를 재구성 하기 위해 -reindex를 사용해야 합니다. 이 명령은 모든 블록체인을 다시 다운로드 할 것 입니다. + 프루닝 해제 모드로 되돌리려면 -reindex로 데이터베이스를 재구성해야 합니다. 이 과정에서 전체 블록체인을 다시 다운로드합니다. Error loading %s: You can't disable HD on an already existing HD wallet @@ -3812,7 +3812,7 @@ Note: Since the fee is calculated on a per-byte basis, a fee of "100 mocha Invalid amount for -paytxfee=<amount>: '%s' (must be at least %s) - 유효하지 않은 금액 -paytxfee=<amount>: "%s" (최소 %s 이상이어야 됨) + 유효하지 않은 금액 -paytxfee=<amount>: "%s" (최소 %s 이상이어야 합니다) Invalid netmask specified in -whitelist: '%s' @@ -3835,8 +3835,8 @@ Note: Since the fee is calculated on a per-byte basis, a fee of "100 mocha 거래액이 수수료를 지불하기엔 너무 작습니다 - This is experimental software. - 이 소프트웨어는 시험적입니다. + This software is under active community maintenance and may change between releases. + 이 소프트웨어는 커뮤니티가 활발히 유지보수 중이며 릴리즈 간 변경될 수 있습니다. Transaction amount too small @@ -3880,7 +3880,7 @@ Note: Since the fee is calculated on a per-byte basis, a fee of "100 mocha -maxtxfee is set very high! Fees this large could be paid on a single transaction. - -maxtxfee값이 너무 큽니다! 하나의 거래에 너무 큰 수수료가 지불 됩니다. + -maxtxfee 값이 너무 큽니다. 단일 거래에 과도한 수수료가 지불될 수 있습니다. Error loading %s: You can't enable HD on an already existing non-HD wallet @@ -3920,7 +3920,7 @@ Note: Since the fee is calculated on a per-byte basis, a fee of "100 mocha Error loading wallet %s. Duplicate -wallet filename specified. - 지갑 %s 로딩 에러, 중복된 -wallet 파일이름을 입력했습니다. + 지갑 %s 로드 오류: 중복된 -wallet 파일 이름이 지정되었습니다. Keypool ran out, please call keypoolrefill first @@ -3972,7 +3972,7 @@ Note: Since the fee is calculated on a per-byte basis, a fee of "100 mocha Fee estimation failed. Fallbackfee is disabled. Wait a few blocks or enable -fallbackfee. - 수수료 견적 실패. Fallbackfee 비활성화 상태. 몇 블록을 기다리거나 -fallbackfee를 활성화 시키십시오. + 수수료 추정에 실패했습니다. -fallbackfee가 비활성화되어 있습니다. 몇 개 블록을 더 기다리거나 -fallbackfee를 활성화하십시오. Warning: Private keys detected in wallet {%s} with disabled private keys diff --git a/src/qt/macdockiconhandler.mm b/src/qt/macdockiconhandler.mm index b9ad191da774..8c063254c4be 100644 --- a/src/qt/macdockiconhandler.mm +++ b/src/qt/macdockiconhandler.mm @@ -16,9 +16,11 @@ static MacDockIconHandler *s_instance = nullptr; -bool dockClickHandler(id self,SEL _cmd,...) { +bool dockClickHandler(id self, SEL _cmd, id sender, bool hasVisibleWindows) { Q_UNUSED(self) Q_UNUSED(_cmd) + Q_UNUSED(sender) + Q_UNUSED(hasVisibleWindows) s_instance->handleDockIconClickEvent(); @@ -28,16 +30,18 @@ bool dockClickHandler(id self,SEL _cmd,...) { void setupDockClickHandler() { Class cls = objc_getClass("NSApplication"); - id appInst = objc_msgSend((id)cls, sel_registerName("sharedApplication")); + id (*objc_msgSend_id)(id, SEL) = reinterpret_cast(objc_msgSend); + id appInst = objc_msgSend_id((id)cls, sel_registerName("sharedApplication")); if (appInst != nullptr) { - id delegate = objc_msgSend(appInst, sel_registerName("delegate")); - Class delClass = (Class)objc_msgSend(delegate, sel_registerName("class")); + id delegate = objc_msgSend_id(appInst, sel_registerName("delegate")); + if (delegate == nullptr) return; + Class delClass = (Class)objc_msgSend_id(delegate, sel_registerName("class")); SEL shouldHandle = sel_registerName("applicationShouldHandleReopen:hasVisibleWindows:"); if (class_getInstanceMethod(delClass, shouldHandle)) - class_replaceMethod(delClass, shouldHandle, (IMP)dockClickHandler, "B@:"); + class_replaceMethod(delClass, shouldHandle, (IMP)dockClickHandler, "B@:@B"); else - class_addMethod(delClass, shouldHandle, (IMP)dockClickHandler,"B@:"); + class_addMethod(delClass, shouldHandle, (IMP)dockClickHandler, "B@:@B"); } } diff --git a/src/qt/mintingtablemodel.cpp b/src/qt/mintingtablemodel.cpp index 6079f6d7d004..009e5227a360 100644 --- a/src/qt/mintingtablemodel.cpp +++ b/src/qt/mintingtablemodel.cpp @@ -591,7 +591,7 @@ static void NotifyTransactionChanged(MintingTableModel *mtm, const uint256 &hash void MintingTableModel::subscribeToCoreSignals() { // Connect signals to wallet - m_handler_transaction_changed = walletModel->wallet().handleTransactionChanged(boost::bind(NotifyTransactionChanged, this, _1, _2)); + m_handler_transaction_changed = walletModel->wallet().handleTransactionChanged(boost::bind(NotifyTransactionChanged, this, boost::placeholders::_1, boost::placeholders::_2)); } void MintingTableModel::unsubscribeFromCoreSignals() diff --git a/src/qt/splashscreen.cpp b/src/qt/splashscreen.cpp index d95c926dbcba..31bd77f3b85d 100644 --- a/src/qt/splashscreen.cpp +++ b/src/qt/splashscreen.cpp @@ -42,7 +42,10 @@ SplashScreen::SplashScreen(interfaces::Node& node, Qt::WindowFlags f, const Netw // define text to place QString titleText = tr(PACKAGE_NAME); QString versionText = QString("Version %1").arg(QString::fromStdString(FormatFullVersion())); - QString copyrightText = QString::fromUtf8(CopyrightHolders(strprintf("\xc2\xA9 %u-%u ", 2018, COPYRIGHT_YEAR)).c_str()); + QString copyrightText = QString::fromUtf8( + "Copyright (C) 2019-2026 The XPChain Community developers\n" + "Copyright (C) 2018-2019 The XPChain Core developers" + ); QString titleAddText = networkStyle->getTitleAddText(); QString font = QApplication::font().toString(); @@ -178,7 +181,7 @@ static void ShowProgress(SplashScreen *splash, const std::string &title, int nPr #ifdef ENABLE_WALLET void SplashScreen::ConnectWallet(std::unique_ptr wallet) { - m_connected_wallet_handlers.emplace_back(wallet->handleShowProgress(boost::bind(ShowProgress, this, _1, _2, false))); + m_connected_wallet_handlers.emplace_back(wallet->handleShowProgress(boost::bind(ShowProgress, this, boost::placeholders::_1, boost::placeholders::_2, false))); m_connected_wallets.emplace_back(std::move(wallet)); } #endif @@ -186,8 +189,8 @@ void SplashScreen::ConnectWallet(std::unique_ptr wallet) void SplashScreen::subscribeToCoreSignals() { // Connect signals to client - m_handler_init_message = m_node.handleInitMessage(boost::bind(InitMessage, this, _1)); - m_handler_show_progress = m_node.handleShowProgress(boost::bind(ShowProgress, this, _1, _2, _3)); + m_handler_init_message = m_node.handleInitMessage(boost::bind(InitMessage, this, boost::placeholders::_1)); + m_handler_show_progress = m_node.handleShowProgress(boost::bind(ShowProgress, this, boost::placeholders::_1, boost::placeholders::_2, boost::placeholders::_3)); #ifdef ENABLE_WALLET m_handler_load_wallet = m_node.handleLoadWallet([this](std::unique_ptr wallet) { ConnectWallet(std::move(wallet)); }); #endif diff --git a/src/qt/trafficgraphwidget.cpp b/src/qt/trafficgraphwidget.cpp index 35569149fcfb..f224cf7e58c1 100644 --- a/src/qt/trafficgraphwidget.cpp +++ b/src/qt/trafficgraphwidget.cpp @@ -7,6 +7,7 @@ #include #include +#include #include #include diff --git a/src/qt/transactiontablemodel.cpp b/src/qt/transactiontablemodel.cpp index e87d88e985bb..a55853872092 100644 --- a/src/qt/transactiontablemodel.cpp +++ b/src/qt/transactiontablemodel.cpp @@ -744,8 +744,8 @@ static void ShowProgress(TransactionTableModel *ttm, const std::string &title, i void TransactionTableModel::subscribeToCoreSignals() { // Connect signals to wallet - m_handler_transaction_changed = walletModel->wallet().handleTransactionChanged(boost::bind(NotifyTransactionChanged, this, _1, _2)); - m_handler_show_progress = walletModel->wallet().handleShowProgress(boost::bind(ShowProgress, this, _1, _2)); + m_handler_transaction_changed = walletModel->wallet().handleTransactionChanged(boost::bind(NotifyTransactionChanged, this, boost::placeholders::_1, boost::placeholders::_2)); + m_handler_show_progress = walletModel->wallet().handleShowProgress(boost::bind(ShowProgress, this, boost::placeholders::_1, boost::placeholders::_2)); } void TransactionTableModel::unsubscribeFromCoreSignals() diff --git a/src/qt/walletmodel.cpp b/src/qt/walletmodel.cpp index 7ca403fb9dc5..4347356da483 100644 --- a/src/qt/walletmodel.cpp +++ b/src/qt/walletmodel.cpp @@ -441,10 +441,10 @@ void WalletModel::subscribeToCoreSignals() // Connect signals to wallet m_handler_unload = m_wallet->handleUnload(boost::bind(&NotifyUnload, this)); m_handler_status_changed = m_wallet->handleStatusChanged(boost::bind(&NotifyKeyStoreStatusChanged, this)); - m_handler_address_book_changed = m_wallet->handleAddressBookChanged(boost::bind(NotifyAddressBookChanged, this, _1, _2, _3, _4, _5)); - m_handler_transaction_changed = m_wallet->handleTransactionChanged(boost::bind(NotifyTransactionChanged, this, _1, _2)); - m_handler_show_progress = m_wallet->handleShowProgress(boost::bind(ShowProgress, this, _1, _2)); - m_handler_watch_only_changed = m_wallet->handleWatchOnlyChanged(boost::bind(NotifyWatchonlyChanged, this, _1)); + m_handler_address_book_changed = m_wallet->handleAddressBookChanged(boost::bind(NotifyAddressBookChanged, this, boost::placeholders::_1, boost::placeholders::_2, boost::placeholders::_3, boost::placeholders::_4, boost::placeholders::_5)); + m_handler_transaction_changed = m_wallet->handleTransactionChanged(boost::bind(NotifyTransactionChanged, this, boost::placeholders::_1, boost::placeholders::_2)); + m_handler_show_progress = m_wallet->handleShowProgress(boost::bind(ShowProgress, this, boost::placeholders::_1, boost::placeholders::_2)); + m_handler_watch_only_changed = m_wallet->handleWatchOnlyChanged(boost::bind(NotifyWatchonlyChanged, this, boost::placeholders::_1)); } void WalletModel::unsubscribeFromCoreSignals() diff --git a/src/rpc/server.cpp b/src/rpc/server.cpp index afb7cb5ba95e..13c03a2964e9 100644 --- a/src/rpc/server.cpp +++ b/src/rpc/server.cpp @@ -509,7 +509,7 @@ std::vector CRPCTable::listCommands() const std::transform( mapCommands.begin(), mapCommands.end(), std::back_inserter(commandList), - boost::bind(&commandMap::value_type::first,_1) ); + boost::bind(&commandMap::value_type::first,boost::placeholders::_1) ); return commandList; } diff --git a/src/torcontrol.cpp b/src/torcontrol.cpp index c88f61f1ec5b..d83d0b291f16 100644 --- a/src/torcontrol.cpp +++ b/src/torcontrol.cpp @@ -459,8 +459,8 @@ TorController::TorController(struct event_base* _base, const std::string& _targe if (!reconnect_ev) LogPrintf("tor: Failed to create event for reconnection: out of memory?\n"); // Start connection attempts immediately - if (!conn.Connect(_target, boost::bind(&TorController::connected_cb, this, _1), - boost::bind(&TorController::disconnected_cb, this, _1) )) { + if (!conn.Connect(_target, boost::bind(&TorController::connected_cb, this, boost::placeholders::_1), + boost::bind(&TorController::disconnected_cb, this, boost::placeholders::_1) )) { LogPrintf("tor: Initiating connection to Tor control port %s failed\n", _target); } // Read service private key if cached @@ -538,7 +538,7 @@ void TorController::auth_cb(TorControlConnection& _conn, const TorControlReply& // Note that the 'virtual' port doesn't have to be the same as our internal port, but this is just a convenient // choice. TODO; refactor the shutdown sequence some day. _conn.Command(strprintf("ADD_ONION %s Port=%i,127.0.0.1:%i", private_key, GetListenPort(), GetListenPort()), - boost::bind(&TorController::add_onion_cb, this, _1, _2)); + boost::bind(&TorController::add_onion_cb, this, boost::placeholders::_1, boost::placeholders::_2)); } else { LogPrintf("tor: Authentication failed\n"); } @@ -597,7 +597,7 @@ void TorController::authchallenge_cb(TorControlConnection& _conn, const TorContr } std::vector computedClientHash = ComputeResponse(TOR_SAFE_CLIENTKEY, cookie, clientNonce, serverNonce); - _conn.Command("AUTHENTICATE " + HexStr(computedClientHash), boost::bind(&TorController::auth_cb, this, _1, _2)); + _conn.Command("AUTHENTICATE " + HexStr(computedClientHash), boost::bind(&TorController::auth_cb, this, boost::placeholders::_1, boost::placeholders::_2)); } else { LogPrintf("tor: Invalid reply to AUTHCHALLENGE\n"); } @@ -646,23 +646,23 @@ void TorController::protocolinfo_cb(TorControlConnection& _conn, const TorContro if (methods.count("HASHEDPASSWORD")) { LogPrint(BCLog::TOR, "tor: Using HASHEDPASSWORD authentication\n"); boost::replace_all(torpassword, "\"", "\\\""); - _conn.Command("AUTHENTICATE \"" + torpassword + "\"", boost::bind(&TorController::auth_cb, this, _1, _2)); + _conn.Command("AUTHENTICATE \"" + torpassword + "\"", boost::bind(&TorController::auth_cb, this, boost::placeholders::_1, boost::placeholders::_2)); } else { LogPrintf("tor: Password provided with -torpassword, but HASHEDPASSWORD authentication is not available\n"); } } else if (methods.count("NULL")) { LogPrint(BCLog::TOR, "tor: Using NULL authentication\n"); - _conn.Command("AUTHENTICATE", boost::bind(&TorController::auth_cb, this, _1, _2)); + _conn.Command("AUTHENTICATE", boost::bind(&TorController::auth_cb, this, boost::placeholders::_1, boost::placeholders::_2)); } else if (methods.count("SAFECOOKIE")) { // Cookie: hexdump -e '32/1 "%02x""\n"' ~/.tor/control_auth_cookie LogPrint(BCLog::TOR, "tor: Using SAFECOOKIE authentication, reading cookie authentication from %s\n", cookiefile); std::pair status_cookie = ReadBinaryFile(cookiefile, TOR_COOKIE_SIZE); if (status_cookie.first && status_cookie.second.size() == TOR_COOKIE_SIZE) { - // _conn.Command("AUTHENTICATE " + HexStr(status_cookie.second), boost::bind(&TorController::auth_cb, this, _1, _2)); + // _conn.Command("AUTHENTICATE " + HexStr(status_cookie.second), boost::bind(&TorController::auth_cb, this, boost::placeholders::_1, boost::placeholders::_2)); cookie = std::vector(status_cookie.second.begin(), status_cookie.second.end()); clientNonce = std::vector(TOR_NONCE_SIZE, 0); GetRandBytes(clientNonce.data(), TOR_NONCE_SIZE); - _conn.Command("AUTHCHALLENGE SAFECOOKIE " + HexStr(clientNonce), boost::bind(&TorController::authchallenge_cb, this, _1, _2)); + _conn.Command("AUTHCHALLENGE SAFECOOKIE " + HexStr(clientNonce), boost::bind(&TorController::authchallenge_cb, this, boost::placeholders::_1, boost::placeholders::_2)); } else { if (status_cookie.first) { LogPrintf("tor: Authentication cookie %s is not exactly %i bytes, as is required by the spec\n", cookiefile, TOR_COOKIE_SIZE); @@ -684,7 +684,7 @@ void TorController::connected_cb(TorControlConnection& _conn) { reconnect_timeout = RECONNECT_TIMEOUT_START; // First send a PROTOCOLINFO command to figure out what authentication is expected - if (!_conn.Command("PROTOCOLINFO 1", boost::bind(&TorController::protocolinfo_cb, this, _1, _2))) + if (!_conn.Command("PROTOCOLINFO 1", boost::bind(&TorController::protocolinfo_cb, this, boost::placeholders::_1, boost::placeholders::_2))) LogPrintf("tor: Error sending initial protocolinfo command\n"); } @@ -711,8 +711,8 @@ void TorController::Reconnect() /* Try to reconnect and reestablish if we get booted - for example, Tor * may be restarting. */ - if (!conn.Connect(target, boost::bind(&TorController::connected_cb, this, _1), - boost::bind(&TorController::disconnected_cb, this, _1) )) { + if (!conn.Connect(target, boost::bind(&TorController::connected_cb, this, boost::placeholders::_1), + boost::bind(&TorController::disconnected_cb, this, boost::placeholders::_1) )) { LogPrintf("tor: Re-initiating connection to Tor control port %s failed\n", target); } } diff --git a/src/utiltime.cpp b/src/utiltime.cpp index 908791da48af..e82dd77f114b 100644 --- a/src/utiltime.cpp +++ b/src/utiltime.cpp @@ -79,7 +79,7 @@ void MilliSleep(int64_t n) std::string FormatISO8601DateTime(int64_t nTime) { struct tm ts; time_t time_val = nTime; -#ifdef _MSC_VER +#if defined(_MSC_VER) || defined(_WIN32) gmtime_s(&ts, &time_val); #else gmtime_r(&time_val, &ts); @@ -90,7 +90,7 @@ std::string FormatISO8601DateTime(int64_t nTime) { std::string FormatISO8601Date(int64_t nTime) { struct tm ts; time_t time_val = nTime; -#ifdef _MSC_VER +#if defined(_MSC_VER) || defined(_WIN32) gmtime_s(&ts, &time_val); #else gmtime_r(&time_val, &ts); @@ -101,7 +101,7 @@ std::string FormatISO8601Date(int64_t nTime) { std::string FormatISO8601Time(int64_t nTime) { struct tm ts; time_t time_val = nTime; -#ifdef _MSC_VER +#if defined(_MSC_VER) || defined(_WIN32) gmtime_s(&ts, &time_val); #else gmtime_r(&time_val, &ts); diff --git a/src/validation.cpp b/src/validation.cpp index bebdd47fc440..c9d730a25adb 100644 --- a/src/validation.cpp +++ b/src/validation.cpp @@ -42,9 +42,11 @@ #include #include +#include #include #include +#include #include #include @@ -1210,6 +1212,8 @@ double_t GetAnnualRate(int nHeight, const Consensus::Params& consensusParams) return 0.05; } + // Defensive fallback for compiler return-path analysis. + return 0.05; } CAmount GetProofOfStakeReward(int nHeight, CAmount nAmount, uint32_t nTime, const Consensus::Params& consensusParams) @@ -2508,11 +2512,11 @@ class ConnectTrace { public: explicit ConnectTrace(CTxMemPool &_pool) : blocksConnected(1), pool(_pool) { - pool.NotifyEntryRemoved.connect(boost::bind(&ConnectTrace::NotifyEntryRemoved, this, _1, _2)); + pool.NotifyEntryRemoved.connect(boost::bind(&ConnectTrace::NotifyEntryRemoved, this, boost::placeholders::_1, boost::placeholders::_2)); } ~ConnectTrace() { - pool.NotifyEntryRemoved.disconnect(boost::bind(&ConnectTrace::NotifyEntryRemoved, this, _1, _2)); + pool.NotifyEntryRemoved.disconnect(boost::bind(&ConnectTrace::NotifyEntryRemoved, this, boost::placeholders::_1, boost::placeholders::_2)); } void BlockConnected(CBlockIndex* pindex, std::shared_ptr pblock) { diff --git a/src/validation.h b/src/validation.h index 20ddb21a47b2..4072a4b4a150 100644 --- a/src/validation.h +++ b/src/validation.h @@ -21,6 +21,7 @@ #include #include +#include #include #include #include diff --git a/src/validationinterface.cpp b/src/validationinterface.cpp index 248e774a8d18..85e600d8129c 100644 --- a/src/validationinterface.cpp +++ b/src/validationinterface.cpp @@ -16,6 +16,7 @@ #include #include +#include #include struct MainSignalsInstance { @@ -60,11 +61,11 @@ size_t CMainSignals::CallbacksPending() { } void CMainSignals::RegisterWithMempoolSignals(CTxMemPool& pool) { - pool.NotifyEntryRemoved.connect(boost::bind(&CMainSignals::MempoolEntryRemoved, this, _1, _2)); + pool.NotifyEntryRemoved.connect(boost::bind(&CMainSignals::MempoolEntryRemoved, this, boost::placeholders::_1, boost::placeholders::_2)); } void CMainSignals::UnregisterWithMempoolSignals(CTxMemPool& pool) { - pool.NotifyEntryRemoved.disconnect(boost::bind(&CMainSignals::MempoolEntryRemoved, this, _1, _2)); + pool.NotifyEntryRemoved.disconnect(boost::bind(&CMainSignals::MempoolEntryRemoved, this, boost::placeholders::_1, boost::placeholders::_2)); } CMainSignals& GetMainSignals() @@ -73,27 +74,27 @@ CMainSignals& GetMainSignals() } void RegisterValidationInterface(CValidationInterface* pwalletIn) { - g_signals.m_internals->UpdatedBlockTip.connect(boost::bind(&CValidationInterface::UpdatedBlockTip, pwalletIn, _1, _2, _3)); - g_signals.m_internals->TransactionAddedToMempool.connect(boost::bind(&CValidationInterface::TransactionAddedToMempool, pwalletIn, _1)); - g_signals.m_internals->BlockConnected.connect(boost::bind(&CValidationInterface::BlockConnected, pwalletIn, _1, _2, _3)); - g_signals.m_internals->BlockDisconnected.connect(boost::bind(&CValidationInterface::BlockDisconnected, pwalletIn, _1)); - g_signals.m_internals->TransactionRemovedFromMempool.connect(boost::bind(&CValidationInterface::TransactionRemovedFromMempool, pwalletIn, _1)); - g_signals.m_internals->ChainStateFlushed.connect(boost::bind(&CValidationInterface::ChainStateFlushed, pwalletIn, _1)); - g_signals.m_internals->Broadcast.connect(boost::bind(&CValidationInterface::ResendWalletTransactions, pwalletIn, _1, _2)); - g_signals.m_internals->BlockChecked.connect(boost::bind(&CValidationInterface::BlockChecked, pwalletIn, _1, _2)); - g_signals.m_internals->NewPoWValidBlock.connect(boost::bind(&CValidationInterface::NewPoWValidBlock, pwalletIn, _1, _2)); + g_signals.m_internals->UpdatedBlockTip.connect(boost::bind(&CValidationInterface::UpdatedBlockTip, pwalletIn, boost::placeholders::_1, boost::placeholders::_2, boost::placeholders::_3)); + g_signals.m_internals->TransactionAddedToMempool.connect(boost::bind(&CValidationInterface::TransactionAddedToMempool, pwalletIn, boost::placeholders::_1)); + g_signals.m_internals->BlockConnected.connect(boost::bind(&CValidationInterface::BlockConnected, pwalletIn, boost::placeholders::_1, boost::placeholders::_2, boost::placeholders::_3)); + g_signals.m_internals->BlockDisconnected.connect(boost::bind(&CValidationInterface::BlockDisconnected, pwalletIn, boost::placeholders::_1)); + g_signals.m_internals->TransactionRemovedFromMempool.connect(boost::bind(&CValidationInterface::TransactionRemovedFromMempool, pwalletIn, boost::placeholders::_1)); + g_signals.m_internals->ChainStateFlushed.connect(boost::bind(&CValidationInterface::ChainStateFlushed, pwalletIn, boost::placeholders::_1)); + g_signals.m_internals->Broadcast.connect(boost::bind(&CValidationInterface::ResendWalletTransactions, pwalletIn, boost::placeholders::_1, boost::placeholders::_2)); + g_signals.m_internals->BlockChecked.connect(boost::bind(&CValidationInterface::BlockChecked, pwalletIn, boost::placeholders::_1, boost::placeholders::_2)); + g_signals.m_internals->NewPoWValidBlock.connect(boost::bind(&CValidationInterface::NewPoWValidBlock, pwalletIn, boost::placeholders::_1, boost::placeholders::_2)); } void UnregisterValidationInterface(CValidationInterface* pwalletIn) { - g_signals.m_internals->BlockChecked.disconnect(boost::bind(&CValidationInterface::BlockChecked, pwalletIn, _1, _2)); - g_signals.m_internals->Broadcast.disconnect(boost::bind(&CValidationInterface::ResendWalletTransactions, pwalletIn, _1, _2)); - g_signals.m_internals->ChainStateFlushed.disconnect(boost::bind(&CValidationInterface::ChainStateFlushed, pwalletIn, _1)); - g_signals.m_internals->TransactionAddedToMempool.disconnect(boost::bind(&CValidationInterface::TransactionAddedToMempool, pwalletIn, _1)); - g_signals.m_internals->BlockConnected.disconnect(boost::bind(&CValidationInterface::BlockConnected, pwalletIn, _1, _2, _3)); - g_signals.m_internals->BlockDisconnected.disconnect(boost::bind(&CValidationInterface::BlockDisconnected, pwalletIn, _1)); - g_signals.m_internals->TransactionRemovedFromMempool.disconnect(boost::bind(&CValidationInterface::TransactionRemovedFromMempool, pwalletIn, _1)); - g_signals.m_internals->UpdatedBlockTip.disconnect(boost::bind(&CValidationInterface::UpdatedBlockTip, pwalletIn, _1, _2, _3)); - g_signals.m_internals->NewPoWValidBlock.disconnect(boost::bind(&CValidationInterface::NewPoWValidBlock, pwalletIn, _1, _2)); + g_signals.m_internals->BlockChecked.disconnect(boost::bind(&CValidationInterface::BlockChecked, pwalletIn, boost::placeholders::_1, boost::placeholders::_2)); + g_signals.m_internals->Broadcast.disconnect(boost::bind(&CValidationInterface::ResendWalletTransactions, pwalletIn, boost::placeholders::_1, boost::placeholders::_2)); + g_signals.m_internals->ChainStateFlushed.disconnect(boost::bind(&CValidationInterface::ChainStateFlushed, pwalletIn, boost::placeholders::_1)); + g_signals.m_internals->TransactionAddedToMempool.disconnect(boost::bind(&CValidationInterface::TransactionAddedToMempool, pwalletIn, boost::placeholders::_1)); + g_signals.m_internals->BlockConnected.disconnect(boost::bind(&CValidationInterface::BlockConnected, pwalletIn, boost::placeholders::_1, boost::placeholders::_2, boost::placeholders::_3)); + g_signals.m_internals->BlockDisconnected.disconnect(boost::bind(&CValidationInterface::BlockDisconnected, pwalletIn, boost::placeholders::_1)); + g_signals.m_internals->TransactionRemovedFromMempool.disconnect(boost::bind(&CValidationInterface::TransactionRemovedFromMempool, pwalletIn, boost::placeholders::_1)); + g_signals.m_internals->UpdatedBlockTip.disconnect(boost::bind(&CValidationInterface::UpdatedBlockTip, pwalletIn, boost::placeholders::_1, boost::placeholders::_2, boost::placeholders::_3)); + g_signals.m_internals->NewPoWValidBlock.disconnect(boost::bind(&CValidationInterface::NewPoWValidBlock, pwalletIn, boost::placeholders::_1, boost::placeholders::_2)); } void UnregisterAllValidationInterfaces() { diff --git a/src/wallet/db.cpp b/src/wallet/db.cpp index 949b296dd826..76c2724dcb5e 100644 --- a/src/wallet/db.cpp +++ b/src/wallet/db.cpp @@ -326,7 +326,7 @@ bool BerkeleyBatch::VerifyEnvironment(const fs::path& file_path, std::string& er LogPrintf("Using wallet %s\n", walletFile); // Wallet file must be a plain filename without a directory - if (walletFile != fs::basename(walletFile) + fs::extension(walletFile)) + if (fs::path(walletFile).filename().string() != walletFile) { errorStr = strprintf(_("Wallet %s resides outside wallet directory %s"), walletFile, walletDir.string()); return false; @@ -779,7 +779,10 @@ bool BerkeleyDatabase::Backup(const std::string& strDest) return false; } - fs::copy_file(pathSrc, pathDest, fs::copy_option::overwrite_if_exists); + if (fs::exists(pathDest)) { + fs::remove(pathDest); + } + fs::copy_file(pathSrc, pathDest); LogPrintf("copied %s to %s\n", strFile, pathDest.string()); return true; } catch (const fs::filesystem_error& e) {