format
This commit is contained in:
parent
74ae55ac52
commit
bddd6caeb2
2 changed files with 9 additions and 9 deletions
|
@ -122,7 +122,7 @@ pub fn smart_write<W: Write>(f: &mut W, writeables: &[Writable]) -> io::Result<(
|
||||||
|
|
||||||
pub trait FormatSteps {
|
pub trait FormatSteps {
|
||||||
fn rename<W: Write>(&self, _f: &mut W, _from: &Path, _to: &Path) -> io::Result<()>;
|
fn rename<W: Write>(&self, _f: &mut W, _from: &Path, _to: &Path) -> io::Result<()>;
|
||||||
fn no_known_extension<W: Write>(&self, _f: &mut W, _path: &Path) -> io::Result<()> ;
|
fn no_known_extension<W: Write>(&self, _f: &mut W, _path: &Path) -> io::Result<()>;
|
||||||
fn unreadable<W: Write>(&self, _f: &mut W, _path: &Path) -> io::Result<()>;
|
fn unreadable<W: Write>(&self, _f: &mut W, _path: &Path) -> io::Result<()>;
|
||||||
fn unknown_type<W: Write>(&self, _f: &mut W, _path: &Path) -> io::Result<()>;
|
fn unknown_type<W: Write>(&self, _f: &mut W, _path: &Path) -> io::Result<()>;
|
||||||
fn header<W: Write>(&self, _f: &mut W, _entries: &Entries) -> io::Result<()>;
|
fn header<W: Write>(&self, _f: &mut W, _entries: &Entries) -> io::Result<()>;
|
||||||
|
|
|
@ -47,14 +47,14 @@ cfg_if! {
|
||||||
// as added by https://github.com/bojand/infer/pull/48/files
|
// as added by https://github.com/bojand/infer/pull/48/files
|
||||||
// this should be removed when (if) that PR is accepted
|
// this should be removed when (if) that PR is accepted
|
||||||
buf.len() > 11
|
buf.len() > 11
|
||||||
&& buf[0] == 0x46
|
&& buf[0] == 0x46
|
||||||
&& buf[1] == 0x4F
|
&& buf[1] == 0x4F
|
||||||
&& buf[2] == 0x52
|
&& buf[2] == 0x52
|
||||||
&& buf[3] == 0x4D
|
&& buf[3] == 0x4D
|
||||||
&& buf[8] == 0x41
|
&& buf[8] == 0x41
|
||||||
&& buf[9] == 0x49
|
&& buf[9] == 0x49
|
||||||
&& buf[10] == 0x46
|
&& buf[10] == 0x46
|
||||||
&& buf[11] == 0x46
|
&& buf[11] == 0x46
|
||||||
});
|
});
|
||||||
|
|
||||||
info.add("image/svg+xml", "svg", |buf| {
|
info.add("image/svg+xml", "svg", |buf| {
|
||||||
|
|
Loading…
Reference in a new issue