rust/src/test
Mazdak Farrokhzad 83d91d3ac4
Rollup merge of #58803 - haraldh:fs_copy_fix, r=alexcrichton
fs::copy() unix: set file mode early

A convenience method like fs::copy() should try to prevent pitfalls a
normal user doesn't think about.

In case of an empty umask, setting the file mode early prevents
temporarily world readable or even writeable files,
because the default mode is 0o666.

In case the target is a named pipe or special device node, setting the
file mode can lead to unwanted side effects, like setting permissons on
`/dev/stdout` or for root setting permissions on `/dev/null`.

copy_file_range() returns EINVAL, if the destination is a FIFO/pipe or
a device like "/dev/null", so fallback to io::copy, too.

Fixes: https://github.com/rust-lang/rust/issues/26933
Fixed: https://github.com/rust-lang/rust/issues/37885
2019-03-28 08:43:29 +01:00
..
assembly Introduce assembly tests 2019-02-27 23:33:05 +01:00
auxiliary Remove licenses 2018-12-25 21:08:33 -07:00
codegen fix some uses I missed 2019-03-26 09:23:19 +01:00
codegen-units Remove licenses 2018-12-25 21:08:33 -07:00
compile-fail Fix a bug in implied bounds 2019-03-20 20:09:26 +01:00
debuginfo Correct minimum system LLVM version in tests 2019-03-22 21:28:25 -05:00
incremental Add no_hash to query macro and move some queries over 2019-03-20 16:06:09 +01:00
mir-opt Auto merge of #59382 - davidtwco:rfc-2008-refactoring, r=petrochenkov 2019-03-24 21:26:57 +00:00
pretty rustc: pass Option<&Substs> and Namespace around in ty::item_path. 2019-03-15 13:25:10 +02:00
run-fail Use the correct state for poisoning a generator 2019-03-03 20:34:26 +00:00
run-make Introduce assembly tests 2019-02-27 23:33:05 +01:00
run-make-fulldeps Move one test from run-make-fulldeps to ui 2019-03-21 23:36:50 +03:00
run-pass Rollup merge of #58803 - haraldh:fs_copy_fix, r=alexcrichton 2019-03-28 08:43:29 +01:00
run-pass-fulldeps Auto merge of #58556 - oli-obk:imperative_recursion, r=pnkfelix 2019-03-15 19:24:15 +00:00
run-pass-valgrind Remove licenses 2018-12-25 21:08:33 -07:00
rustdoc Auto merge of #58927 - GuillaumeGomez:default-keyword, r=QuietMisdreavus 2019-03-21 08:55:50 +00:00
rustdoc-js Move rustdoc-js testing into compiletest 2019-02-28 18:08:48 +01:00
rustdoc-js-std Rename rustdoc js test suites 2019-02-25 17:46:06 +01:00
rustdoc-ui use ! in macro disambiguation suggestion 2019-03-15 15:12:30 -04:00
rustfix tests: Do not use -Z parse-only, continue compilation to test recovery 2019-01-06 22:20:46 +03:00
ui Rollup merge of #59459 - JohnTitor:add-tests, r=Centril 2019-03-27 18:15:42 -07:00
ui-fulldeps Moved issue tests to subdirs and normalised names. 2019-03-14 01:00:49 +00:00
COMPILER_TESTS.md rustc-guide has moved 2018-11-26 15:03:13 -06:00