1
0
mirror of https://github.com/fluencelabs/sqlite synced 2025-05-12 08:57:12 +00:00

Compare commits

..

No commits in common. "master" and "sqlite-wasm-v0.18.1" have entirely different histories.

9 changed files with 40 additions and 67 deletions

@ -1,3 +1,3 @@
{
".": "0.18.2"
".": "0.18.1"
}

@ -27,12 +27,23 @@ jobs:
mv wasi-sdk-* wasi-sdk
- name: Setup Rust toolchain
uses: dsherret/rust-toolchain-file@v1
uses: actions-rust-lang/setup-rust-toolchain@v1
- name: Download marine artifact
id: marine
uses: actions/download-artifact@v3
continue-on-error: true
with:
name: marine
path: ~/.local/bin
- name: Make marine executable
if: steps.marine.outcome == 'success'
run: chmod +x ~/.local/bin/marine
- name: Setup marine
if: steps.marine.outcome == 'failure'
uses: fluencelabs/setup-marine@v1
with:
artifact-name: "marine"
- name: Build sqlite-wasm
run: make

@ -30,9 +30,6 @@ concurrency:
jobs:
build:
name: "sqlite"
if: >
github.event_name == 'push' ||
contains(github.event.pull_request.labels.*.name, 'e2e')
uses: ./.github/workflows/build.yml
with:
ref: ${{ github.ref }}
@ -56,26 +53,11 @@ jobs:
}
]
decider:
rust-peer:
needs:
- spell
uses: fluencelabs/decider/.github/workflows/snapshot.yml@main
with:
cargo-dependencies: |
[
{
"package": "fluence-spell-dtos",
"version": "=${{ needs.spell.outputs.cargo-version }}",
"registry": "fluence"
}
]
nox:
needs:
- spell
- decider
uses: fluencelabs/nox/.github/workflows/build.yml@master
uses: fluencelabs/rust-peer/.github/workflows/build.yml@master
with:
cargo-dependencies: |
[
@ -88,39 +70,35 @@ jobs:
"package": "fluence-spell-distro",
"version": "=${{ needs.spell.outputs.cargo-version }}",
"registry": "fluence"
},
{
"package": "decider-distro",
"version": "=${{ needs.decider.outputs.cargo-version }}",
"manifest": "crates/system-services/Cargo.toml",
"registry": "fluence"
}
]
nox-snapshot:
name: "nox"
rust-peer-snapshot:
name: "rust-peer"
needs:
- nox
- rust-peer
uses: fluencelabs/nox/.github/workflows/container.yml@master
uses: fluencelabs/rust-peer/.github/workflows/container.yml@master
with:
image-name: "docker.fluence.dev/sqlite"
image-name: "docker.fluence.dev/sqlite-wasm-connector"
flavour: "minimal"
rust-peer-sha: "${{ needs.rust-peer.outputs.rust-peer-sha }}"
spell-aqua-tests:
name: "spell"
needs:
- nox-snapshot
- rust-peer-snapshot
uses: fluencelabs/spell/.github/workflows/tests.yml@main
with:
nox-image: "${{ needs.nox-snapshot.outputs.nox-image }}"
rust-peer-image: "${{ needs.rust-peer-snapshot.outputs.rust-peer-image }}"
registry:
needs:
- snapshot
- nox-snapshot
- rust-peer-snapshot
uses: fluencelabs/registry/.github/workflows/tests.yml@main
with:
nox-image: "${{ needs.nox-snapshot.outputs.nox-image }}"
rust-peer-image: "${{ needs.rust-peer-snapshot.outputs.rust-peer-image }}"
cargo-dependencies: |
[
{

@ -1,12 +1,5 @@
# Changelog
## [0.18.2](https://github.com/fluencelabs/sqlite/compare/sqlite-wasm-v0.18.1...sqlite-wasm-v0.18.2) (2023-12-25)
### Bug Fixes
* fix use-after-free when using sqlite_bind_text/sqlite_bind_blob with sqlite_step ([#24](https://github.com/fluencelabs/sqlite/issues/24)) ([13a62f2](https://github.com/fluencelabs/sqlite/commit/13a62f2b1017e2e5e860951bf01516c0aea739a0))
## [0.18.1](https://github.com/fluencelabs/sqlite/compare/sqlite-wasm-v0.18.0...sqlite-wasm-v0.18.1) (2023-04-06)

@ -7,9 +7,10 @@ RUN apt update \
git \
make \
pkg-config \
libtinfo6
libtinfo6 \
cargo
RUN mkdir -p ~/.local/bin && curl -L https://github.com/fluencelabs/marine/releases/download/marine-v0.14.1/marine-linux-x86_64 -o ~/.local/bin/marine && chmod +x ~/.local/bin/marine
RUN cargo install marine --version 0.12.7
VOLUME /code
WORKDIR /code

@ -1,5 +1,4 @@
export PATH="${PATH}:/root/.cargo/bin:/root/.local/bin"
export PATH="${PATH}:/root/.cargo/bin"
curl -L https://github.com/WebAssembly/wasi-sdk/releases/download/wasi-sdk-15/wasi-sdk-15.0-linux.tar.gz | tar xz -C .
rm -rf wasi-sdk
mv -f wasi-sdk-* wasi-sdk
mv wasi-sdk-* wasi-sdk
make

@ -1,9 +0,0 @@
[toolchain]
channel = "nightly-2023-08-27"
components = [
"rustfmt",
"clippy",
]
targets = [
"x86_64-unknown-linux-gnu",
]

@ -1537,11 +1537,11 @@ int sqlite3_bind_blob_(sqlite3_stmt *pStmt, int i, const void *zData, int nData,
return SQLITE_MISUSE_BKPT;
#endif
// xDel is a custom deallocator and due to our IT architecture it can't be provided from other modules.
// xDel is a custom deallocator and if it is not SQLITE_STATIC
// due to our IT architecture it can't be provided from other modules.
// However the memory zData uses has to be cleaned up eventually.
// So, it is cleared as intended in IT, and xDel is set to SQLITE_TRANSIENT to make sqlite copy the data.
add_object_to_release((void*)zData);
return bindText(pStmt, i, zData, nData, SQLITE_TRANSIENT, 0);
return bindText(pStmt, i, zData, nData, xDel, 0);
}
#endif
@ -1613,11 +1613,11 @@ int sqlite3_bind_text(sqlite3_stmt *pStmt, int i, const char *zData, int nData,
int sqlite3_bind_text_(sqlite3_stmt *pStmt, int i, const char *zData, int nData,
void (*xDel)(void *))
__attribute__((export_name("sqlite3_bind_text"))) {
// xDel is a custom deallocator and due to our IT architecture it can't be provided from other modules.
// xDel is a custom deallocator and if it is not SQLITE_STATIC
// due to our IT architecture it can't be provided from other modules.
// However the memory zData uses has to be cleaned up eventually.
// So, it is cleared as intended in IT, and xDel is set to SQLITE_TRANSIENT to make sqlite copy the data.
add_object_to_release((void*)zData);
return bindText(pStmt, i, zData, nData, SQLITE_TRANSIENT, SQLITE_UTF8);
return bindText(pStmt, i, zData, nData, xDel, SQLITE_UTF8);
}
#endif

@ -1 +1 @@
0.18.2
0.18.1