Fix warnings.

This commit is contained in:
Rafał Harabień 2017-10-07 16:45:11 +02:00
parent 6355db8073
commit 37f52e4024
2 changed files with 2 additions and 3 deletions

View File

@ -4,7 +4,6 @@ extern crate chrono;
use std::env; use std::env;
use std::fs::File; use std::fs::File;
use std::io::BufReader; use std::io::BufReader;
use std::str;
use chrono::{DateTime, Local}; use chrono::{DateTime, Local};
use fatfs::FileSystem; use fatfs::FileSystem;

View File

@ -87,8 +87,8 @@ pub struct FileSystem<'a> {
impl <'a> FileSystem<'a> { impl <'a> FileSystem<'a> {
pub fn new<T: ReadSeek>(mut rdr: &'a mut T) -> io::Result<FileSystem<'a>> { pub fn new<T: ReadSeek>(rdr: &'a mut T) -> io::Result<FileSystem<'a>> {
let boot = Self::read_boot_record(&mut *rdr)?; let boot = Self::read_boot_record(rdr)?;
if boot.boot_sig != [0x55, 0xAA] { if boot.boot_sig != [0x55, 0xAA] {
return Err(Error::new(ErrorKind::Other, "invalid signature")); return Err(Error::new(ErrorKind::Other, "invalid signature"));
} }