summary refs log tree commit diff
path: root/sys_util/src/shm.rs
diff options
context:
space:
mode:
authorDavid Tolnay <dtolnay@chromium.org>2019-03-08 15:57:49 -0800
committerchrome-bot <chrome-bot@chromium.org>2019-03-13 21:05:03 -0700
commitfe3ef7d99892fad804cbc9de8801033fd483f337 (patch)
treeb07b227d98466d14e61660d144e85109bc632abd /sys_util/src/shm.rs
parentfa132759424c5019dc9086e53d8db14500fee64f (diff)
downloadcrosvm-fe3ef7d99892fad804cbc9de8801033fd483f337.tar
crosvm-fe3ef7d99892fad804cbc9de8801033fd483f337.tar.gz
crosvm-fe3ef7d99892fad804cbc9de8801033fd483f337.tar.bz2
crosvm-fe3ef7d99892fad804cbc9de8801033fd483f337.tar.lz
crosvm-fe3ef7d99892fad804cbc9de8801033fd483f337.tar.xz
crosvm-fe3ef7d99892fad804cbc9de8801033fd483f337.tar.zst
crosvm-fe3ef7d99892fad804cbc9de8801033fd483f337.zip
edition: Update absolute paths to 2018 style
This is an easy step toward adopting 2018 edition eventually, and will
make any future CL that sets `edition = "2018"` this much smaller.

The module system changes in Rust 2018 are described here:

https://doc.rust-lang.org/edition-guide/rust-2018/module-system/path-clarity.html

Generated by running:

    cargo fix --edition --all

in each workspace, followed by bin/fmt.

TEST=cargo check
TEST=cargo check --all-features
TEST=cargo check --target aarch64-unknown-linux-gnu

Change-Id: I000ab5e69d69aa222c272fae899464bbaf65f6d8
Reviewed-on: https://chromium-review.googlesource.com/1513054
Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com>
Tested-by: David Tolnay <dtolnay@chromium.org>
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: David Tolnay <dtolnay@chromium.org>
Diffstat (limited to 'sys_util/src/shm.rs')
-rw-r--r--sys_util/src/shm.rs6
1 files changed, 2 insertions, 4 deletions
diff --git a/sys_util/src/shm.rs b/sys_util/src/shm.rs
index 6f74ecf..4b5f7d9 100644
--- a/sys_util/src/shm.rs
+++ b/sys_util/src/shm.rs
@@ -11,11 +11,9 @@ use libc::{
     self, c_char, c_int, c_long, c_uint, close, fcntl, ftruncate64, off64_t, syscall, F_ADD_SEALS,
     F_GET_SEALS, F_SEAL_GROW, F_SEAL_SEAL, F_SEAL_SHRINK, F_SEAL_WRITE, MFD_ALLOW_SEALING,
 };
-
-use errno;
 use syscall_defines::linux::LinuxSyscall::SYS_memfd_create;
 
-use {errno_result, Result};
+use crate::{errno, errno_result, Result};
 
 /// A shared memory file descriptor and its size.
 pub struct SharedMemory {
@@ -219,7 +217,7 @@ mod tests {
 
     use data_model::VolatileMemory;
 
-    use MemoryMapping;
+    use crate::MemoryMapping;
 
     #[test]
     fn new() {