diff --git a/libherokubuildpack/src/write.rs b/libherokubuildpack/src/write.rs index a7bd0221..1a2bbff1 100644 --- a/libherokubuildpack/src/write.rs +++ b/libherokubuildpack/src/write.rs @@ -16,7 +16,7 @@ pub fn mapped) -> Vec) + Sync + Send + 'static> MappedWrite::new(w, marker_byte, f) } -/// Constructs a writer that buffers written data until an ASCII/UTF-8 newline byte (`0x0A`) is +/// Constructs a writer that buffers written data until an ASCII/UTF-8 newline byte (`b'\n'`) is /// encountered and then applies the given mapping function to the data before passing the result to /// the wrapped writer. /// @@ -25,7 +25,7 @@ pub fn line_mapped) -> Vec) + Sync + Send + 'st w: W, f: F, ) -> MappedWrite { - mapped(w, NEWLINE_ASCII_BYTE, f) + mapped(w, b'\n', f) } /// Constructs a writer that writes to two other writers. Similar to the UNIX `tee` command. @@ -155,8 +155,6 @@ impl io::Write for TeeWrite { } } -const NEWLINE_ASCII_BYTE: u8 = 0x0Au8; - #[cfg(test)] mod test { use super::tee;