<feed xmlns='http://www.w3.org/2005/Atom'>
<title>rust/src/libstd/sys/windows, branch 1.45.2</title>
<subtitle>https://github.com/rust-lang/rust
</subtitle>
<id>http://git.dreamy.place/mirrors/rust/atom?h=1.45.2</id>
<link rel='self' href='http://git.dreamy.place/mirrors/rust/atom?h=1.45.2'/>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/'/>
<updated>2020-05-17T21:38:31+00:00</updated>
<entry>
<title>abort_internal is safe</title>
<updated>2020-05-17T21:38:31+00:00</updated>
<author>
<name>Ralf Jung</name>
<email>post@ralfj.de</email>
</author>
<published>2020-05-17T17:37:44+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=2764673dca6badb2ef89450bbdd84b19c317a9c7'/>
<id>urn:sha1:2764673dca6badb2ef89450bbdd84b19c317a9c7</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Replace `cfg` macro with attribute.</title>
<updated>2020-05-02T15:06:16+00:00</updated>
<author>
<name>Markus Reiter</name>
<email>me@reitermark.us</email>
</author>
<published>2020-05-02T05:05:22+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=39a97900bee062b020c93e995c3b48b48d335bf2'/>
<id>urn:sha1:39a97900bee062b020c93e995c3b48b48d335bf2</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Update name</title>
<updated>2020-04-26T11:24:16+00:00</updated>
<author>
<name>Steven Fackler</name>
<email>sfackler@gmail.com</email>
</author>
<published>2020-03-12T01:02:52+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=07443f17d4c2e8135d1cbf415f6bd22eee86b64a'/>
<id>urn:sha1:07443f17d4c2e8135d1cbf415f6bd22eee86b64a</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Add Read/Write::can_read/write_vectored</title>
<updated>2020-04-26T11:23:39+00:00</updated>
<author>
<name>Steven Fackler</name>
<email>sfackler@gmail.com</email>
</author>
<published>2020-01-03T19:26:05+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=15262ec6be6fcfc9f27e174a0714d5a62e775fb0'/>
<id>urn:sha1:15262ec6be6fcfc9f27e174a0714d5a62e775fb0</id>
<content type='text'>
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
</content>
</entry>
<entry>
<title>Add missing comma</title>
<updated>2020-04-14T13:29:39+00:00</updated>
<author>
<name>Youngsuk Kim</name>
<email>joseph942010@gmail.com</email>
</author>
<published>2020-04-14T13:29:39+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=de143312f8c7c137f09418878045a48331463d19'/>
<id>urn:sha1:de143312f8c7c137f09418878045a48331463d19</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Rollup merge of #67705 - lzutao:wmemchr, r=wesleywiser</title>
<updated>2020-04-09T03:29:36+00:00</updated>
<author>
<name>Mazdak Farrokhzad</name>
<email>twingoow@gmail.com</email>
</author>
<published>2020-04-09T03:29:36+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=e89cb0733a33906f2097ed3511f6766a95432a3b'/>
<id>urn:sha1:e89cb0733a33906f2097ed3511f6766a95432a3b</id>
<content type='text'>
Use unrolled loop for searching NULL in [u16] on Windows
</content>
</entry>
<entry>
<title>Forward OsStr::clone_into to the inner Vec</title>
<updated>2020-04-07T01:26:37+00:00</updated>
<author>
<name>Josh Stone</name>
<email>jistone@redhat.com</email>
</author>
<published>2020-03-20T22:46:40+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=f854070bb820501d88d1b029660bfde663595530'/>
<id>urn:sha1:f854070bb820501d88d1b029660bfde663595530</id>
<content type='text'>
Despite OS differences, they're all just `Vec&lt;u8&gt;` inside, so we can
just forward `clone_into` calls to that optimized implementation.
</content>
</entry>
<entry>
<title>Rollup merge of #70597 - vakaras:thread_new_double_free_bug_fix, r=Amanieu</title>
<updated>2020-04-03T20:55:05+00:00</updated>
<author>
<name>Mazdak Farrokhzad</name>
<email>twingoow@gmail.com</email>
</author>
<published>2020-04-03T20:55:05+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=1ea8653d0116365e09dca7b22c7264d0fc877433'/>
<id>urn:sha1:1ea8653d0116365e09dca7b22c7264d0fc877433</id>
<content type='text'>
Fix double-free and undefined behaviour in libstd::syn::unix::Thread::new

While working on concurrency support for Miri, I found that the `libstd::syn::unix::Thread::new` method has two potential problems: double-free and undefined behaviour.

**Double-free** could occur if the following events happened (credit for pointing this out goes to @RalfJung):

1.  The call to `pthread_create` successfully launched a new thread that executed to completion and deallocated `p`.
2.  The call to `pthread_attr_destroy` returned a non-zero value causing the `assert_eq!` to panic.
3.  Since `mem::forget(p)` was not yet executed, the destructor of `p` would be executed and cause a double-free.

As far as I understand, this code also violates the stacked-borrows aliasing rules and thus would result in **undefined behaviour** if these rules were adopted.  The problem is that the ownership of `p` is passed to the newly created thread before the call to `mem::forget`. Since the call to `mem::forget` is still a call, it counts as a use of `p` and triggers UB.

This pull request changes the code to use `mem::ManuallyDrop` instead of `mem::forget`. As a consequence, in case of a panic, `p` would be potentially leaked, which while undesirable is probably better than double-free or undefined behaviour.
</content>
</entry>
<entry>
<title>Use unrolled loop</title>
<updated>2020-04-02T02:43:23+00:00</updated>
<author>
<name>lzutao</name>
<email>taolzu@gmail.com</email>
</author>
<published>2020-04-02T02:43:23+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=89bc23643bc4ba979f28d6df8c091813c89c36a9'/>
<id>urn:sha1:89bc23643bc4ba979f28d6df8c091813c89c36a9</id>
<content type='text'>
</content>
</entry>
<entry>
<title>use of wmemchr for faster searching in [u16]</title>
<updated>2020-04-02T02:41:38+00:00</updated>
<author>
<name>Lzu Tao</name>
<email>taolzu@gmail.com</email>
</author>
<published>2019-12-29T15:47:13+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=041e1704fcd9cc932a4fa587c43d32ed9dcb9712'/>
<id>urn:sha1:041e1704fcd9cc932a4fa587c43d32ed9dcb9712</id>
<content type='text'>
</content>
</entry>
</feed>
