Skip to content

Commit 2a1e61e

Browse files
committed
avoid creating unnecessary reference in Windows Env iterator
1 parent 7b73d14 commit 2a1e61e

File tree

1 file changed

+1
-1
lines changed
  • src/libstd/sys/windows

1 file changed

+1
-1
lines changed

src/libstd/sys/windows/os.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ impl Iterator for Env {
9494
if *self.cur == 0 {
9595
return None;
9696
}
97-
let p = &*self.cur as *const u16;
97+
let p = self.cur as *const u16;
9898
let mut len = 0;
9999
while *p.offset(len) != 0 {
100100
len += 1;

0 commit comments

Comments
 (0)