Skip to content

Commit 1347809

Browse files
djcrami3l
authored andcommitted
Upgrade windows-sys to 0.59
1 parent 4e459f5 commit 1347809

File tree

6 files changed

+19
-7
lines changed

6 files changed

+19
-7
lines changed

Cargo.lock

+10-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

+4-1
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,7 @@ features = [
102102
"Win32_Foundation",
103103
"Win32_Security",
104104
"Win32_Storage_FileSystem",
105+
"Win32_System_Console",
105106
"Win32_System_Diagnostics_ToolHelp",
106107
"Win32_System_IO",
107108
"Win32_System_Ioctl",
@@ -112,8 +113,10 @@ features = [
112113
"Win32_System_SystemServices",
113114
"Win32_System_Threading",
114115
"Win32_System_WindowsProgramming",
116+
"Win32_UI",
117+
"Win32_UI_WindowsAndMessaging",
115118
]
116-
version = "0.52.0"
119+
version = "0.59"
117120

118121
[dev-dependencies]
119122
enum-map = "2.5.0"

src/cli/job.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ mod imp {
6868
// we're otherwise part of someone else's job object in this case.
6969

7070
let job = CreateJobObjectW(ptr::null_mut(), ptr::null());
71-
if job == 0 {
71+
if job.is_null() {
7272
return None;
7373
}
7474
let job = Handle { inner: job };

src/cli/self_update/windows.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -438,7 +438,7 @@ pub(crate) fn wait_for_parent() -> Result<()> {
438438

439439
// Get a handle to the parent process
440440
let parent = OpenProcess(SYNCHRONIZE, 0, parent_id);
441-
if parent == 0 {
441+
if parent.is_null() {
442442
// This just means the parent has already exited.
443443
return Ok(());
444444
}
@@ -783,7 +783,7 @@ pub(crate) fn delete_rustup_and_cargo_home(process: &Process) -> Result<()> {
783783
&sa,
784784
OPEN_EXISTING,
785785
FILE_FLAG_DELETE_ON_CLOSE,
786-
0,
786+
ptr::null_mut(),
787787
);
788788

789789
if gc_handle == INVALID_HANDLE_VALUE {

src/dist/mod.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -422,7 +422,7 @@ impl TargetTriple {
422422
)
423423
-> BOOL = unsafe {
424424
let module = GetModuleHandleA(s!("kernel32.dll"));
425-
if module == 0 {
425+
if module.is_null() {
426426
return None;
427427
}
428428
mem::transmute(GetProcAddress(module, s!("IsWow64Process2"))?)

src/utils/raw.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ fn symlink_junction_inner(target: &Path, junction: &Path) -> io::Result<()> {
185185
ptr::null_mut(),
186186
OPEN_EXISTING,
187187
FILE_FLAG_OPEN_REPARSE_POINT | FILE_FLAG_BACKUP_SEMANTICS,
188-
0,
188+
ptr::null_mut(),
189189
);
190190

191191
let mut data = [0u8; MAXIMUM_REPARSE_DATA_BUFFER_SIZE];

0 commit comments

Comments
 (0)