Skip to content

Commit fcfe91c

Browse files
committed
---
yaml --- r: 274093 b: refs/heads/stable c: ae30294 h: refs/heads/master i: 274091: f699821
1 parent c614731 commit fcfe91c

File tree

3 files changed

+10
-4
lines changed

3 files changed

+10
-4
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ refs/heads/tmp: e06d2ad9fcd5027bcaac5b08fc9aa39a49d0ecd3
2929
refs/tags/1.0.0-alpha.2: 4c705f6bc559886632d3871b04f58aab093bfa2f
3030
refs/tags/homu-tmp: c0221c8897db309a79990367476177b1230bb264
3131
refs/tags/1.0.0-beta: 8cbb92b53468ee2b0c2d3eeb8567005953d40828
32-
refs/heads/stable: 9c569189c8b8b5d635b6704c489a8410c81570a0
32+
refs/heads/stable: ae30294771e3c5c65a2d70be0e09b5bec2490c66
3333
refs/tags/1.0.0: 55bd4f8ff2b323f317ae89e254ce87162d52a375
3434
refs/tags/1.1.0: bc3c16f09287e5545c1d3f76b7abd54f2eca868b
3535
refs/tags/1.2.0: f557861f822c34f07270347b94b5280de20a597e

branches/stable/src/libstd/fs.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2264,6 +2264,12 @@ mod tests {
22642264
assert_eq!(check!(fs::metadata(&tmpdir.join("h"))).len(), 9);
22652265
}
22662266

2267+
#[test]
2268+
fn _assert_send_sync() {
2269+
fn _assert_send_sync<T: Send + Sync>() {}
2270+
_assert_send_sync::<OpenOptions>();
2271+
}
2272+
22672273
#[test]
22682274
fn binary_file() {
22692275
let mut bytes = [0; 1024];

branches/stable/src/libstd/sys/windows/fs.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ pub struct OpenOptions {
6969
attributes: c::DWORD,
7070
share_mode: c::DWORD,
7171
security_qos_flags: c::DWORD,
72-
security_attributes: c::LPSECURITY_ATTRIBUTES,
72+
security_attributes: usize, // FIXME: should be a reference
7373
}
7474

7575
#[derive(Clone, PartialEq, Eq, Debug)]
@@ -170,7 +170,7 @@ impl OpenOptions {
170170
share_mode: c::FILE_SHARE_READ | c::FILE_SHARE_WRITE | c::FILE_SHARE_DELETE,
171171
attributes: 0,
172172
security_qos_flags: 0,
173-
security_attributes: ptr::null_mut(),
173+
security_attributes: 0,
174174
}
175175
}
176176

@@ -187,7 +187,7 @@ impl OpenOptions {
187187
pub fn attributes(&mut self, attrs: u32) { self.attributes = attrs; }
188188
pub fn security_qos_flags(&mut self, flags: u32) { self.security_qos_flags = flags; }
189189
pub fn security_attributes(&mut self, attrs: c::LPSECURITY_ATTRIBUTES) {
190-
self.security_attributes = attrs;
190+
self.security_attributes = attrs as usize;
191191
}
192192

193193
fn get_access_mode(&self) -> io::Result<c::DWORD> {

0 commit comments

Comments
 (0)