Skip to content

Commit

Permalink
Fix typos
Browse files Browse the repository at this point in the history
  • Loading branch information
ncihnegn committed Jun 9, 2024
1 parent 23684c8 commit 827a3a0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
5 changes: 1 addition & 4 deletions src/archive.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ use crate::error::TarError;
use crate::header::{SparseEntry, BLOCK_SIZE};
use crate::other;
use crate::pax::*;
use crate::{Entry, GnuExtSparseHeader, GnuSparseHeader, Header};
use crate::{Entry, GnuExtSparseHeader, Header};

/// A top-level representation of an archive file.
///
Expand Down Expand Up @@ -422,9 +422,6 @@ impl<'a> EntriesFields<'a> {
));
}
pax_extensions = Some(EntryFields::from(entry).read_all()?);
if let Some(pax_extensions_ref) = &pax_extensions {
pax_size = pax_extensions_size(pax_extensions_ref);
}
// This entry has two headers.
// Keep pax_extensions for the next ustar header.
processed -= 1;
Expand Down
4 changes: 2 additions & 2 deletions src/header.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,14 @@ use std::str;
use crate::other;
use crate::EntryType;

pub const BLOCK_SIZE: usize = 51
pub const BLOCK_SIZE: usize = 512;
/// A deterministic, arbitrary, non-zero timestamp that use used as `mtime`
/// of headers when [`HeaderMode::Deterministic`] is used.
///
/// This value, chosen after careful deliberation, corresponds to _Jul 23, 2006_,
/// which is the date of the first commit for what would become Rust.
#[cfg(any(unix, windows))]
const DETERMINISTIC_TIMESTAMP: u64 = 115370408
const DETERMINISTIC_TIMESTAMP: u64 = 1153704088;

/// Representation of the header of an entry in an archive
#[repr(C)]
Expand Down

0 comments on commit 827a3a0

Please sign in to comment.