Commit Graph

2414 Commits

Author SHA1 Message Date
Mark McCaskey
7a7aa4608a fix emscripten regression tests 2019-05-29 11:41:29 -07:00
Mark McCaskey
6606a7c7b0 silence clippy on pointer alignment 2019-05-28 14:06:24 -07:00
Mark McCaskey
f8b94b7469 Merge remote-tracking branch 'origin/master' into feature/add-mapdir-for-emscripten 2019-05-28 13:48:12 -07:00
Mark McCaskey
3a4517d5d6 clean up code, verify it behaves the same as emscripten with js 2019-05-28 10:06:22 -07:00
Syrus Akbary
ef4908d3bc
Fix security contact 2019-05-27 14:41:18 -07:00
Syrus Akbary
df03fc1fd3
Added Security Policy. Fixed #468 2019-05-27 13:57:17 -07:00
bors[bot]
813b57b40e Merge #465
465: Running jq r=syrusakbary a=syrusakbary

This PR does:
* Add the functions needed to run jq
* Refactor how varargs strings are handled (to simplify them)

Co-authored-by: Syrus <me@syrusakbary.com>
Co-authored-by: Syrus Akbary <me@syrusakbary.com>
2019-05-27 20:25:25 +00:00
Syrus
fe3db46173 Fixed time ptr 2019-05-27 12:47:15 -07:00
Syrus
12299cdbf0 Merge branch 'master' into feature/jq 2019-05-27 12:13:19 -07:00
Syrus
6fd6ad92fa Trying to fix timegm 2019-05-27 12:09:04 -07:00
bors[bot]
69f0f7d666 Merge #469
469: Update wasmparser 0.29.2 -> 0.30.0 r=MarkMcCaskey a=repi

Updated to the latest version of wasmparser

Co-authored-by: Johan Andersson <repi@repi.se>
2019-05-25 01:01:18 +00:00
Mark McCaskey
fc15bc58f6 add mapdir for emscripten; implement getdents, etc. 2019-05-24 18:00:07 -07:00
Johan Andersson
8018453266 Update wasmparser 0.29.2 -> 0.30.0 2019-05-24 23:18:08 +02:00
Syrus
dd30595358 Trying to fix issues 2019-05-24 13:30:41 -07:00
Syrus
dd9c5774f3 Separate fpathconf from pathconf 2019-05-24 12:15:52 -07:00
Syrus
c7dceba0d8 Improved formatting 2019-05-24 12:09:00 -07:00
Syrus
e0895aadf1 Merge branch 'master' into feature/jq 2019-05-24 12:08:28 -07:00
bors[bot]
e8c9715099 Merge #467
467: feat(runtime-c-api) `wasmer_instantiate` raises the source error r=syrusakbary a=Hywan

Instead of returning only “error instanting”, `wasmer_instantiate` can
return the real error message.

Co-authored-by: Ivan Enderlin <ivan.enderlin@hoa-project.net>
Co-authored-by: Syrus Akbary <me@syrusakbary.com>
2019-05-24 18:26:04 +00:00
Syrus Akbary
42327a569e
Merge branch 'master' into feat-runtime-error 2019-05-24 11:25:40 -07:00
Syrus Akbary
4dab51f620
Merge branch 'master' into feat-runtime-error 2019-05-24 11:18:50 -07:00
Syrus
e0187ab9dc Improved lint cache 2019-05-24 11:13:12 -07:00
Syrus
36b9366767 Commented runtime-abi for now 2019-05-24 11:00:57 -07:00
Syrus
02a92562f6 Removed zbox requirement 2019-05-24 10:13:08 -07:00
Ivan Enderlin
dc6a53bff7 chore(changelog) Add #467. 2019-05-24 14:28:37 +02:00
Ivan Enderlin
90676b5c5b feat(runtime-c-api) wasmer_instantiate raises the source error.
Instead of returning only “error instanting”, `wasmer_instantiate` can
return the real error message.
2019-05-24 14:24:00 +02:00
Syrus Akbary
dc6092edd5
Merge branch 'master' into feature/jq 2019-05-23 09:50:02 -07:00
bors[bot]
dcf0a7cc4b Merge #463
463: Prevent parent directory from being opened without being preopened wasi r=MarkMcCaskey a=MarkMcCaskey

resolves  #462

Because the logic of opening a directory and traversing the tree are separate, we allowed one level of `..` to be opened beyond what was preopened

The diff on github isn't clear, but this adds an if and then puts the previous logic in an else block

Co-authored-by: Mark McCaskey <mark@wasmer.io>
2019-05-22 23:00:10 +00:00
Mark McCaskey
dc3ac156a4 add test, update changelog 2019-05-22 15:57:12 -07:00
Mark McCaskey
b7abc44648 Prevent parent directory from being opened without being preopened wasi 2019-05-22 15:30:38 -07:00
bors[bot]
5ff9e74a88 Merge #461
461: fix(runtime-c-api) Prevent negative lengths in various places r=Hywan a=Hywan

This PR prevents receiving negative lengths in various places in the code.

Co-authored-by: Ivan Enderlin <ivan.enderlin@hoa-project.net>
2019-05-22 14:57:18 +00:00
Ivan Enderlin
43a2448e5c doc(changelog) Add #461. 2019-05-22 16:49:08 +02:00
Ivan Enderlin
11f1bbaf9a chore(runtime-c-api) Update C/C++ header files. 2019-05-22 16:45:59 +02:00
Ivan Enderlin
c92230e18e fix(runtime-c-api) Lengths cannot be negative.
This patch prevents receiving negative length in various places.
2019-05-22 16:44:03 +02:00
Syrus
f79ff8b542 Merge branch 'master' into feature/jq 2019-05-21 17:15:12 -07:00
bors[bot]
32c2ad1916 Merge #447
447: add trace macro for more verbose debug statements r=MarkMcCaskey a=MarkMcCaskey

The next step is to implement these in terms of `log`

Co-authored-by: Mark McCaskey <mark@wasmer.io>
Co-authored-by: Mark McCaskey <markmccaskey@users.noreply.github.com>
2019-05-21 19:28:34 +00:00
Mark McCaskey
c12b9541c6 update changelog 2019-05-21 11:46:35 -07:00
Mark McCaskey
3bedf6218c
Merge branch 'master' into feature/trace-macro 2019-05-21 11:44:50 -07:00
bors[bot]
699d65bddb Merge #459
459: add realtime and monotonic clock support for wasi on windows r=MarkMcCaskey a=MarkMcCaskey

resolves #455 

Co-authored-by: Mark McCaskey <mark@wasmer.io>
2019-05-21 18:36:08 +00:00
bors[bot]
7b9e289f68 Merge #456
456: Command/openssl r=syrusakbary a=piranna

Mocks for missing functions needed by `openssl` command.

Co-authored-by: Jesús Leganés-Combarro 'piranna <piranna@gmail.com>
2019-05-21 18:23:59 +00:00
Mark McCaskey
deb00c886c change to depend on winapi only on windows 2019-05-21 11:23:24 -07:00
Mark McCaskey
8857e6d320 move check with debug build higher in CI, fix bug in debug macro 2019-05-21 11:15:13 -07:00
Mark McCaskey
e989a86d33 properly handle bad input on windows clocks 2019-05-21 10:55:54 -07:00
Mark McCaskey
2a30fc3f1b wrap call in unsafe, unconditionally depend on winapi 2019-05-21 10:41:40 -07:00
Mark McCaskey
736bddfe17 debug log error in windows clock, conditionally pull in winapi 2019-05-21 10:35:51 -07:00
Mark McCaskey
08b4b639f4 add realtime and monotonic clock support for wasi on windows 2019-05-21 10:24:06 -07:00
Jesús Leganés-Combarro 'piranna
490b94b814 Fix linting 2019-05-21 19:12:35 +02:00
bors[bot]
f3220a0435 Merge #451
451: implement map-dir for WASI; fix bug in path_open r=MarkMcCaskey a=MarkMcCaskey

Colon separated mapping, implemented to be compatible with wasmtime

resolves #458 

example:
```Rust
use std::fs;

fn main() {
    let read_dir = fs::read_dir(".").unwrap();
    for entry in read_dir {
        println!("{:?}", entry.unwrap().path());
    }
}
```
```shell
$ cargo run --release --bin wasmer -- run --mapdir=.:src list-files.wasm
"./bin"
"./installer"
"./lib"
"./update"
"./utils"
"./webassembly"
```

Co-authored-by: Mark McCaskey <mark@wasmer.io>
Co-authored-by: Mark McCaskey <markmccaskey@users.noreply.github.com>
2019-05-21 01:01:27 +00:00
Mark McCaskey
54a91a1b99 make wasi regression tests single threaded 2019-05-20 17:56:43 -07:00
Mark McCaskey
6b81ec0aa7 add mapdir regression test; add testfs; add arg passing system 2019-05-20 17:43:50 -07:00
Mark McCaskey
7734001c1c update plugin example to pass empty vec for mapped_dir arg 2019-05-20 16:50:56 -07:00