mirror of
https://github.com/redstrate/Physis.git
synced 2025-04-23 05:07:46 +00:00
Fix misc warnings
This commit is contained in:
parent
59913434e6
commit
6f9b5c59d7
4 changed files with 3 additions and 6 deletions
|
@ -1,6 +1,5 @@
|
||||||
use std::fs;
|
use std::fs;
|
||||||
use std::path::PathBuf;
|
use std::path::PathBuf;
|
||||||
use crate::gamedata::MemoryBuffer;
|
|
||||||
use crate::patch::{apply_patch, PatchError};
|
use crate::patch::{apply_patch, PatchError};
|
||||||
|
|
||||||
/// Boot data for FFXIV.
|
/// Boot data for FFXIV.
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
use std::ffi::CString;
|
|
||||||
use std::fs::read;
|
use std::fs::read;
|
||||||
use std::io::Cursor;
|
use std::io::Cursor;
|
||||||
use binrw::binrw;
|
use binrw::binrw;
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
use std::fs;
|
use std::fs;
|
||||||
use std::fs::DirEntry;
|
use std::fs::DirEntry;
|
||||||
use std::path::{Path, PathBuf};
|
use std::path::PathBuf;
|
||||||
use crate::common::Language;
|
use crate::common::Language;
|
||||||
use crate::dat::DatFile;
|
use crate::dat::DatFile;
|
||||||
use crate::exd::EXD;
|
use crate::exd::EXD;
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
use std::io::{Cursor, Seek, SeekFrom};
|
use std::io::{Cursor, Seek, SeekFrom};
|
||||||
use std::os::unix::raw::time_t;
|
|
||||||
use binrw::binread;
|
use binrw::binread;
|
||||||
use crate::gamedata::MemoryBuffer;
|
use crate::gamedata::MemoryBuffer;
|
||||||
use binrw::BinRead;
|
use binrw::BinRead;
|
||||||
|
@ -71,7 +70,7 @@ impl ChatLog {
|
||||||
let content_offset = (8 + header.file_size * 4) as u64;
|
let content_offset = (8 + header.file_size * 4) as u64;
|
||||||
|
|
||||||
// beginning of content offset
|
// beginning of content offset
|
||||||
cursor.seek(SeekFrom::Start(content_offset));
|
cursor.seek(SeekFrom::Start(content_offset)).ok()?;
|
||||||
|
|
||||||
let mut entries = vec![];
|
let mut entries = vec![];
|
||||||
|
|
||||||
|
@ -83,7 +82,7 @@ impl ChatLog {
|
||||||
// TODO: handle the coloring properly, in some way
|
// TODO: handle the coloring properly, in some way
|
||||||
entry.message = String::from_utf8_lossy(&*buffer[cursor.position() as usize..new_last_offset as usize].to_vec()).to_string();
|
entry.message = String::from_utf8_lossy(&*buffer[cursor.position() as usize..new_last_offset as usize].to_vec()).to_string();
|
||||||
|
|
||||||
cursor.seek(SeekFrom::Start(new_last_offset));
|
cursor.seek(SeekFrom::Start(new_last_offset)).ok()?;
|
||||||
|
|
||||||
entries.push(entry);
|
entries.push(entry);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue