about summary refs log tree commit diff
path: root/src/libstd/sys/vxworks
AgeCommit message (Collapse)AuthorLines
2020-07-27mv std libs to library/mark-4805/+0
2020-07-23Prefer constant over functionLzu Tao-12/+10
2020-07-15Rollup merge of #74291 - regexident:from-docs, r=GuillaumeGomezManish Goregaokar-0/+1
Added docs for `From<c_int>` for `ExitStatus` Partially addresses https://github.com/rust-lang/rust/issues/51430
2020-07-14Added docs for `From<c_int>` for `ExitStatus`Vincent Esche-0/+1
2020-07-12adjust remaining targetsRalf Jung-6/+2
2020-07-02Fix linksGuillaume Gomez-1/+1
2020-06-23Remove unused crate imports in 2018 edition cratesyuqio-6/+0
2020-06-10Migrate to numeric associated constsLzu Tao-13/+9
2020-05-25Auto merge of #72472 - LeSeulArtichaut:sync-command, r=dtolnaybors-2/+4
Implement `Sync` for `process::Command on unix and vxworks Closes #72387. r? @cuviper
2020-05-22Implement `Sync` for `process::Command on unix and vxworksLeSeulArtichaut-2/+4
2020-05-22Rollup merge of #72123 - jsgf:stabilize-arg0, r=sfacklerRalf Jung-1/+1
Stabilize process_set_argv0 feature for Unix This stabilizes process_set_argv0 targeting 1.45.0. It has been useful in practice and seems useful as-is. The equivalent feature could be implemented for Windows, but as far as I know nobody has. That can be done separately. Tracking issue: #66510
2020-05-17abort_internal is safeRalf Jung-2/+2
2020-05-12Stabilize process_set_argv0 feature for UnixJeremy Fitzhardinge-1/+1
This stabilizes process_set_argv0 targeting 1.45.0. It has been useful in practice and seems useful as-is. The equivalent feature could be implemented for Windows, but as far as I know nobody has. That can be done separately. Tracking issue: #66510
2020-04-26Update nameSteven Fackler-14/+14
2020-04-26Add Read/Write::can_read/write_vectoredSteven Fackler-0/+41
When working with an arbitrary reader or writer, code that uses vectored operations may end up being slower than code that copies into a single buffer when the underlying reader or writer doesn't actually support vectored operations. These new methods allow you to ask the reader or witer up front if vectored operations are efficiently supported. Currently, you have to use some heuristics to guess by e.g. checking if the read or write only accessed the first buffer. Hyper is one concrete example of a library that has to do this dynamically: https://github.com/hyperium/hyper/blob/0eaf304644a396895a4ce1f0146e596640bb666a/src/proto/h1/io.rs#L582-L594
2020-04-01In Thread::new, add a comment that a panic could cause a memory leak.Vytautas Astrauskas-1/+4
2020-03-31Use Box::into_raw instead of ManuallyDrop in Thread::new.Vytautas Astrauskas-9/+4
2020-03-31Inline start_thread into its callers.Vytautas Astrauskas-4/+6
2020-03-31Fix double-free and undefined behaviour in libstd::syn::unix::Thread::new.Vytautas Astrauskas-3/+10
2020-03-21Rollup merge of #69955 - alexcrichton:stderr-infallible, r=sfacklerDylan DPC-2/+2
Fix abort-on-eprintln during process shutdown This commit fixes an issue where if `eprintln!` is used in a TLS destructor it can accidentally cause the process to abort. TLS destructors are executed after `main` returns on the main thread, and at this point we've also deinitialized global `Lazy` values like those which store the `Stderr` and `Stdout` internals. This means that despite handling TLS not being accessible in `eprintln!`, we will fail due to not being able to call `stderr()`. This means that we'll double-panic quickly because panicking also attempt to write to stderr. The fix here is to reimplement the global stderr handle to avoid the need for destruction. This avoids the need for `Lazy` as well as the hidden panic inside of the `stderr` function. Overall this should improve the robustness of printing errors and/or panics in weird situations, since the `stderr` accessor should be infallible in more situations.
2020-03-20Fix abort-on-eprintln during process shutdownAlex Crichton-2/+2
This commit fixes an issue where if `eprintln!` is used in a TLS destructor it can accidentally cause the process to abort. TLS destructors are executed after `main` returns on the main thread, and at this point we've also deinitialized global `Lazy` values like those which store the `Stderr` and `Stdout` internals. This means that despite handling TLS not being accessible in `eprintln!`, we will fail due to not being able to call `stderr()`. This means that we'll double-panic quickly because panicking also attempt to write to stderr. The fix here is to reimplement the global stderr handle to avoid the need for destruction. This avoids the need for `Lazy` as well as the hidden panic inside of the `stderr` function. Overall this should improve the robustness of printing errors and/or panics in weird situations, since the `stderr` accessor should be infallible in more situations.
2020-03-14Rollup merge of #69403 - LeSeulArtichaut:copy-ioslice, r=sfacklerYuki Okushi-0/+1
Implement `Copy` for `IoSlice` Resolves #69395 r? @sfackler
2020-03-06fix various typosMatthias Krüger-1/+1
2020-02-23Implement `Copy` for `IoSlice`LeSeulArtichaut-0/+1
2020-01-25Rollup merge of #68515 - Wind-River:master_2020, r=alexcrichtonYuki Okushi-5/+39
Support feature process_set_argv0 for VxWorks r? @alexcrichton
2020-01-24Support feature process_set_argv0 for VxWorksBaoshanPang-5/+39
2020-01-10make use of pointer::is_nullLzu Tao-4/+3
2020-01-06ignore signal SIGPIPEBaoshanPang-10/+2
2020-01-06Remove weak.rs for VxWorksUmesh Kalappa-56/+0
2020-01-04Rollup merge of #67848 - ollie27:float_link_name_attr, r=Dylan-DPCGuillaume Gomez-1/+0
Remove unused `#[link_name = "m"]` attributes These were perhaps supposed to be `#[link(name = "m")]` but linking libm should be handled by the libc crate anyway. They should have triggered a compile error: #47725
2020-01-03Remove unused `#[link_name = "m"]` attributesOliver Middleton-1/+0
These were perhaps supposed to be `#[link(name = "m")]` but linking libm should be handled by the libc crate anyway.
2020-01-02Use drop instead of the toilet closure `|_| ()`Lzu Tao-7/+7
2019-12-24Deprecate Error::description for realDavid Tolnay-0/+1
`description` has been documented as soft-deprecated since 1.27.0 (17 months ago). There is no longer any reason to call it or implement it. This commit: - adds #[rustc_deprecated(since = "1.41.0")] to Error::description; - moves description (and cause, which is also deprecated) below the source and backtrace methods in the Error trait; - reduces documentation of description and cause to take up much less vertical real estate in rustdocs, while preserving the example that shows how to render errors without needing to call description; - removes the description function of all *currently unstable* Error impls in the standard library; - marks #[allow(deprecated)] the description function of all *stable* Error impls in the standard library; - replaces miscellaneous uses of description in example code and the compiler.
2019-12-22Format the worldMark Rousskov-67/+80
2019-12-21Require issue = "none" over issue = "0" in unstable attributesRoss MacArthur-2/+2
2019-12-20Remove `SOCK_CLOEXEC` dummy variable on platforms that don't use it.Markus Reiter-2/+0
2019-12-18Remove `SO_NOSIGPIPE` dummy variable on platforms that don't use it.Markus Reiter-1/+0
2019-12-06Rollup merge of #67041 - Wind-River:master_base, r=alexcrichtonYuki Okushi-0/+3
add ExitStatusExt into prelude r? @alexcrichton
2019-12-06Rollup merge of #66649 - Wind-River:master_xyz, r=alexcrichtonYuki Okushi-9/+22
VxWorks: fix issues in accessing environment variables
2019-12-03add ExitStatusExt into preludeBaoshanPang-0/+3
2019-11-29Format libstd/sys with rustfmtDavid Tolnay-480/+524
This commit applies rustfmt with rust-lang/rust's default settings to files in src/libstd/sys *that are not involved in any currently open PR* to minimize merge conflicts. THe list of files involved in open PRs was determined by querying GitHub's GraphQL API with this script: https://gist.github.com/dtolnay/aa9c34993dc051a4f344d1b10e4487e8 With the list of files from the script in outstanding_files, the relevant commands were: $ find src/libstd/sys -name '*.rs' \ | xargs rustfmt --edition=2018 --unstable-features --skip-children $ rg libstd/sys outstanding_files | xargs git checkout -- Repeating this process several months apart should get us coverage of most of the rest of the files. To confirm no funny business: $ git checkout $THIS_COMMIT^ $ git show --pretty= --name-only $THIS_COMMIT \ | xargs rustfmt --edition=2018 --unstable-features --skip-children $ git diff $THIS_COMMIT # there should be no difference
2019-11-22ensure that access to the environment is synchronizedBaoshanPang-9/+18
2019-11-22pass the captured environment variables to rtpSpawnBaoshanPang-1/+5
2019-11-05Rollup merge of #66091 - Wind-River:master_xyz, r=cramertjPietro Albini-1/+2
Implemented the home_dir for VxWorks Use HOME's value if it is set; otherwise return NONE.
2019-11-05Rollup merge of #65905 - cuviper:doc-unix-mode, r=Dylan-DPCPietro Albini-2/+2
[doc] fixes for unix/vxworks `OpenOptionsExt::mode`
2019-11-04Implemented the home_dir for VxWorksUmesh Kalappa-1/+2
2019-10-29vxWorks: remove all code related to UNIX socket as it is not supported by ↵BaoshanPang-1828/+60
vxWorks
2019-10-28[doc] fix the reference to using `OpenOptions::open`Josh Stone-1/+1
2019-10-28[doc] add a possessive apostrophe in `OpenOptionsExt::mode`Josh Stone-1/+1
2019-10-13Rollup merge of #65246 - Wind-River:real_master_2, r=kennytmMazdak Farrokhzad-6/+20
vxWorks: implement get_path() and get_mode() for File fmt::Debug