about summary refs log tree commit diff
path: root/src/libstd/sys
AgeCommit message (Collapse)AuthorLines
2016-12-29Rollup merge of #38622 - alexcrichton:read-lengths, r=sfacklerAlex Crichton-12/+24
std: Clamp max read/write sizes on Unix Turns out that even though all these functions take a `size_t` they don't actually work that well with anything larger than the maximum value of `ssize_t`, the return value. Furthermore it looks like OSX rejects any read/write requests larger than `INT_MAX - 1`. Handle all these cases by just clamping the maximum size of a read/write on Unix to a platform-specific value. Closes #38590
2016-12-27Fix arguments on RedoxJeremy Soller-9/+5
2016-12-27Auto merge of #38577 - redox-os:master, r=alexcrichtonbors-2/+3
Add Debug to OpenOptions and DirBuilder This fixes the build on Redox as the platform independent structs now implement Debug.
2016-12-26Auto merge of #38274 - elahn:windows-readconsole-ctrl-z, r=alexcrichtonbors-4/+33
Ctrl-Z returns from Stdin.read() when reading from the console on Windows Fixes #19914. Fixes read(), read_to_string(), read_to_end(), etc. r? @alexcrichton
2016-12-26std: Clamp max read/write sizes on UnixAlex Crichton-12/+24
Turns out that even though all these functions take a `size_t` they don't actually work that well with anything larger than the maximum value of `ssize_t`, the return value. Furthermore it looks like OSX rejects any read/write requests larger than `INT_MAX - 1`. Handle all these cases by just clamping the maximum size of a read/write on Unix to a platform-specific value. Closes #38590
2016-12-24Rollup merge of #38521 - jxson:remove-magenta-warnings, r=sfacklerSteve Klabnik-1/+0
Removes magenta build warning. Small bug fix to remove an unused type in the magenta process code that causes build failures for magenta's rustc. r? @alexcrichton @tedsta @raphlinus
2016-12-23Cloexec when creating directoriesJeremy Soller-1/+1
2016-12-23Add Debug to OpenOptions and DirBuilderJeremy Soller-1/+2
2016-12-23Auto merge of #38401 - redox-os:redox_cross, r=brsonbors-22/+1317
Redox Cross Compilation I will admit - there are things here that I wish I did not have to do. This completes the ability to create a cross compiler from the rust repository for `x86_64-unknown-redox`. I will document this PR with inline comments explaining some things. [View this gist to see how a cross compiler is built](https://gist.github.com/jackpot51/6680ad973986e84d69c79854249f2b7e) Prior discussion of a smaller change is here: https://github.com/rust-lang/rust/pull/38366
2016-12-22Remove start functions, use newlib instead of openlibm + rallocJeremy Soller-155/+0
2016-12-21Add RawFd traits for netJeremy Soller-15/+64
2016-12-21Removes magenta build warning.Jason Campbell-1/+0
Small bug fix to remove an unused type in the magenta process code that causes build failures for magenta's rustc.
2016-12-20Fix tidyJeremy Soller-3/+6
2016-12-20Fix building without backtraceJeremy Soller-0/+1
2016-12-20Readd statvfsJeremy Soller-0/+26
2016-12-20Move rt into sys::rt, fix tidyJeremy Soller-334/+161
2016-12-20Fix compile errors and suchAlex Crichton-4/+5
2016-12-20Rollup merge of #38236 - GuillaumeGomez:unix_socket_doc, r=frewsxcvAlex Crichton-26/+566
Unix socket doc r? @frewsxcv
2016-12-20Rollup merge of #38006 - frewsxcv:libstd-debug, r=alexcrichtonAlex Crichton-2/+12
Implement `fmt::Debug` for all structures in libstd. Part of https://github.com/rust-lang/rust/issues/31869. Also turn on the `missing_debug_implementations` lint at the crate level.
2016-12-20Add arm syscallsJeremy Soller-2/+78
2016-12-18Implement `fmt::Debug` for all structures in libstd.Corey Farwell-2/+12
Part of https://github.com/rust-lang/rust/issues/31869. Also turn on the `missing_debug_implementations` lint at the crate level.
2016-12-18Auto merge of #38051 - sanxiyn:unused-type-alias-3, r=eddybbors-3/+2
Warn unused type aliases, reimplemented Reimplementation of #37631. Fix #37455.
2016-12-18Fix WindowsSeo Sanghyeon-3/+2
2016-12-16Address falloutAaron Turon-1/+1
2016-12-16Add missing doc examples for UnixDatagramGuillaume Gomez-38/+285
2016-12-15Add start functions, switch allocation crate to rallocJeremy Soller-3/+78
2016-12-15WIP: Cross-compilation for Redox targetJeremy Soller-7/+1400
2016-12-15Stabilize std::os::unix::process::CommandExt::before_execAaron Turon-1/+1
2016-12-15Stabilize std::os::*::fs::FileExtAaron Turon-10/+10
2016-12-12Fix tidy checksJeremy Soller-1/+2
2016-12-12Merge branch 'master' into redoxJeremy Soller-250/+731
2016-12-12Fix accidental removal of importJeremy Soller-0/+1
2016-12-12Rollback prefixJeremy Soller-3/+3
2016-12-10Ctrl-Z returns from Stdin.read() when reading from the console onElahn Ientile-4/+33
Windows. Fixes #19914. Fixes read(), read_to_string(), read_to_end(), etc.
2016-12-09Auto merge of #38197 - mneumann:dragonfly-fixes-2016-12-06, r=alexcrichtonbors-7/+2
Fix current_exe() on DragonFly (again) This is a follow up on [this pull request][1]. Since DragonFly 4.6.1 ([this commit][2]), the ```kern.proc.pathname``` sysctl works correctly, i.e. it does not return paths including a ```:``` (see [here][3]). Use it and don't try to fix old versions of DragonFly! There are not many DragonFly installations out there that we can't control and no one is compiling Rust from source. If someone wants to run Rust on a pre-4.6.1 DragonFly system, the ports system should provide a patch. [1]: https://github.com/rust-lang/rust/pull/35494 [2]: https://gitweb.dragonflybsd.org/dragonfly.git/commit/726f7ca07e193db73635e9c4e24e40c96087d6d9 [3]: https://gist.github.com/mneumann/a2f6b6a0a03935b561d6185872a4b222
2016-12-08Add Incoming doc examplesGuillaume Gomez-3/+30
2016-12-08Add UnixListener doc examplesGuillaume Gomez-10/+101
2016-12-08Add doc examples for UnixStreamGuillaume Gomez-6/+145
2016-12-08Add missing doc examples for SocketAddr structGuillaume Gomez-0/+36
2016-12-08Auto merge of #38146 - kali:master, r=alexcrichtonbors-2/+15
fix objc ABI in std::env::args iOS use different calling convention for `objc_msgSend` depending on the platform. armv7 expect good old variadic arguments, but aarch64 wants "normal" convention: `objc_msgSend` has to be called mimicking the actual callee prototype. https://developer.apple.com/library/content/documentation/General/Conceptual/CocoaTouch64BitGuide/ConvertingYourAppto64-Bit/ConvertingYourAppto64-Bit.html#//apple_ref/doc/uid/TP40013501-CH3-SW26 This currently breaks std::env:args() on aarch64 iOS devices. As far as I can tell, in the standard library, this is the only occurrence of ObjectiveC dispatching.
2016-12-07Rollup merge of #38153 - GuillaumeGomez:typo, r=blussGuillaume Gomez-1/+1
Fix small typo
2016-12-06Fix current_exe() on DragonFly (again)Michael Neumann-7/+2
This is a follow up on [this pull request][1]. Since DragonFly 4.6.1 ([this commit][2]), the "kern.proc.pathname" sysctl works correctly, i.e. it does not return paths including a ":" (see [here][3]). Use it and don't try to fix old versions of DragonFly! There are not many DragonFly installations out there that we can't control and no one is compiling Rust from source. If someone wants to run Rust on a pre-4.6.1 DragonFly system, the ports system should provide a patch. [1]: https://github.com/rust-lang/rust/pull/35494 [2]: https://gitweb.dragonflybsd.org/dragonfly.git/commit/726f7ca07e193db73635e9c4e24e40c96087d6d9 [3]: https://gist.github.com/mneumann/a2f6b6a0a03935b561d6185872a4b222
2016-12-05Auto merge of #38098 - luser:windows-commandext, r=alexcrichtonbors-2/+26
Add std::os::windows::process::CommandExt. Fixes #37827 This adds a CommandExt trait for Windows along with an implementation of it for std::process::Command with methods to set the process creation flags that are passed to CreateProcess.
2016-12-04Fix small typoGuillaume Gomez-1/+1
2016-12-03fix objc ABI in std::env::argsMathieu Poumeyrol-2/+15
2016-12-02Auto merge of #37936 - tedsta:fuchsia_std_process, r=alexcrichtonbors-238/+687
Fuchsia support for std::process via liblaunchpad. Now we can launch processes on Fuchsia via the Rust standard library! ... Mostly. Right now, ~5% of the time, reading the stdout/stderr off the pipes will fail. Some Magenta kernel people think it's probably a bug in Magenta's pipes. I wrote a unit test that demonstrates the issue in C, which I was told will expedite a fix. https://fuchsia-review.googlesource.com/#/c/15628/ Hopefully this can get merged once the issue is fixed :) @raphlinus
2016-12-01std::process fuchsia support cleanupTheodore DeRego-34/+26
2016-11-30Cleanup envJeremy Soller-4/+5
2016-11-30just add one method named creation_flags, fix the tidy errorTed Mielczarek-17/+4
2016-11-30Add std::os::windows::process::CommandExt, with set_creation_flags and ↵Ted Mielczarek-2/+39
add_creation_flags methods. Fixes #37827 This adds a CommandExt trait for Windows along with an implementation of it for std::process::Command with methods to set the process creation flags that are passed to CreateProcess.