Skip to content

Conversation

thomcc
Copy link
Member

@thomcc thomcc commented Sep 5, 2022

This basically a subset of the changes from #101171. I didn't think to look in src/bootstrap for more windows filesystem API usage, which was apparently a mistake on my part. It's kinda goofy that stuff like this is in here, but what are you gonna do, computers are awful.

I also added winbase to the winapi dep -- I tested this in a tmp crate but needed to add this to your Cargo.toml -- you use winapi::stuff::winbase in this function, but are relying on something else turning on that feature.

@thomcc thomcc added the T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) label Sep 5, 2022
@rust-highfive
Copy link
Contributor

r? @Mark-Simulacrum

(rust-highfive has picked a reviewer for you, use r? to override)

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Sep 5, 2022
Copy link
Member

@jyn514 jyn514 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this seems fine, yeah. r=me if you want.

Is there no safe way to make a symlink on windows??

@ChrisDenton
Copy link
Member

This makes a juncture point, which is like a symlink but only works on directories. I would assume the reason it's used here is because it works without special permissions or developer mode being enabled.

Perhaps std should expose a safe API.

@thomcc
Copy link
Member Author

thomcc commented Sep 7, 2022

@bors r=jyn514

@bors
Copy link
Collaborator

bors commented Sep 7, 2022

📌 Commit 850090d has been approved by jyn514

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Sep 7, 2022
Dylan-DPC added a commit to Dylan-DPC/rust that referenced this pull request Sep 7, 2022
Avoid UB in the Windows filesystem code in... bootstrap?

This basically a subset of the changes from rust-lang#101171. I didn't think to look in src/bootstrap for more windows filesystem API usage, which was apparently a mistake on my part. It's kinda goofy that stuff like this is in here, but what are you gonna do, computers are awful.

I also added `winbase` to the `winapi` dep -- I tested this in a tmp crate but needed to add this to your Cargo.toml -- you `use winapi::stuff::winbase` in this function, but are relying on something else turning on that feature.
Dylan-DPC added a commit to Dylan-DPC/rust that referenced this pull request Sep 7, 2022
Avoid UB in the Windows filesystem code in... bootstrap?

This basically a subset of the changes from rust-lang#101171. I didn't think to look in src/bootstrap for more windows filesystem API usage, which was apparently a mistake on my part. It's kinda goofy that stuff like this is in here, but what are you gonna do, computers are awful.

I also added `winbase` to the `winapi` dep -- I tested this in a tmp crate but needed to add this to your Cargo.toml -- you `use winapi::stuff::winbase` in this function, but are relying on something else turning on that feature.
bors added a commit to rust-lang-ci/rust that referenced this pull request Sep 8, 2022
Rollup of 6 pull requests

Successful merges:

 - rust-lang#101153 (Migrate another part of rustc_infer to session diagnostic)
 - rust-lang#101399 (Shrink span for bindings with subpatterns.)
 - rust-lang#101422 (Hermit: Add File::set_time stub)
 - rust-lang#101455 (Avoid UB in the Windows filesystem code in... bootstrap?)
 - rust-lang#101498 (rustc: Parameterize `ty::Visibility` over used ID)
 - rust-lang#101549 (Use HashStable_Generic in rustc_type_ir)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 1c35596 into rust-lang:master Sep 8, 2022
@rustbot rustbot added this to the 1.65.0 milestone Sep 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants