1
0
mirror of synced 2024-11-30 18:34:29 +01:00

sys: Literally, fuck Valve

This commit is contained in:
WerWolv 2022-11-02 08:24:00 +01:00
parent 948b5b2d9c
commit a6742de405
14 changed files with 6 additions and 65 deletions

View File

@ -525,64 +525,3 @@ jobs:
name: Fedora ${{ matrix.release }} RPM
path: |
imhex-${{env.IMHEX_VERSION}}-Fedora-${{matrix.release}}.rpm
steam_deploy:
needs: [ win, macos, ubuntu ]
runs-on: ubuntu-latest
name: 🚀 Steam Deployment Nightly
if: github.event_name == 'push' && github.repository == 'WerWolv/ImHex' && github.ref == 'refs/heads/master'
steps:
- name: 🧰 Checkout
uses: actions/checkout@v3
with:
path: ImHex
- name: 📜 Set version variable
run: |
project_version=`cat ImHex/VERSION`
echo "IMHEX_VERSION=$project_version" >> $GITHUB_ENV
- name: ⬇️ Download Windows Artifact
uses: actions/download-artifact@v3
with:
name: Windows Portable
path: ./steam/windows
- name: ⬇️ Download macOS Artifact
uses: actions/download-artifact@v3
with:
name: macOS Portable
path: ./steam/macos
- name: ⬇️ Download Linux Artifact
uses: actions/download-artifact@v3
with:
name: Linux AppImage
path: ./steam/linux
- name: 🗜️ Setup steam depots
run: |
mv steam/linux/imhex-${{env.IMHEX_VERSION}}.AppImage steam/linux/imhex.AppImage
- name: 🗝️ Generate Steam TOTP
uses: CyberAndrii/steam-totp@v1
id: steam-totp
with:
shared_secret: ${{ secrets.STEAM_SHARED_SECRET }}
- name: 💨 Publish Steam Nightly
uses: game-ci/steam-deploy@main
with:
username: ${{ secrets.STEAM_USERNAME }}
password: ${{ secrets.STEAM_PASSWORD }}
totp: ${{ steps.steam-totp.outputs.code }}
appId: 2186040
buildDescription: v${{ env.IMHEX_VERSION }} - ${{ github.sha }}
rootPath: ./steam
depot1Path: windows
depot2Path: macos
depot3Path: linux
releaseBranch: nightly

View File

@ -14,7 +14,7 @@ namespace hex::prv {
public:
explicit BufferedReader(Provider *provider, size_t bufferSize = 16_MiB)
: m_provider(provider), m_bufferAddress(provider->getBaseAddress()), m_maxBufferSize(bufferSize),
m_startAddress(0x00), m_endAddress(provider->getActualSize() - 1),
m_startAddress(provider->getBaseAddress()), m_endAddress(provider->getBaseAddress() + provider->getActualSize() - 1),
m_buffer(bufferSize) {
}

View File

@ -288,9 +288,11 @@ namespace hex::plugin::builtin {
}
std::optional<Region> findSequence(const std::vector<u8> &sequence, bool backwards) {
hex::prv::BufferedReader reader(ImHexApi::Provider::get());
auto provider = ImHexApi::Provider::get();
reader.seek(this->m_searchPosition.value_or(0x00));
hex::prv::BufferedReader reader(provider);
reader.seek(this->m_searchPosition.value_or(provider->getBaseAddress()));
constexpr static auto searchFunction = [](const auto &haystackBegin, const auto &haystackEnd, const auto &needleBegin, const auto &needleEnd) {
return std::search(haystackBegin, haystackEnd, std::boyer_moore_horspool_searcher(needleBegin, needleEnd));

Binary file not shown.

Before

Width:  |  Height:  |  Size: 43 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 258 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 98 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 315 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 74 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 154 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 116 KiB