Benign cargo Download

error.rs

SHA-2561c7023cefe6f870f39dcb016f4a9a428494399ce9c4fd27307cdb3c6db651b5a
Malecule∅

Evidence

imports std::convert::Infallible lines 1–10
1use std::convert::Infallible;
2use std::error::Error as StdError;
3use std::fmt::{self, Display};
4use std::io;
5use std::result;
6
7/// Errors than can occur while parsing the response from the server.
8#[derive(Debug)]
9pub enum InvalidResponseKind {
10 /// Invalid or mi …
imports InvalidResponseKind::* lines 24–33
24:26… ength header
25 ContentLength,
26}
27
28impl Display for InvalidResponseKind {
29 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
30 use InvalidResponseKind::*;
31
32 match self {
33 LocationHeader => write!(f, "missing or invalid location hea …
English function-word token "that" lines 40–48
40:56… length"),
41 }
42 }
43}
44
45/// Common errors that can occur during HTTP requests.
46#[derive(Debug)]
47pub enum ErrorKind {
48 /// CONNECT is not su …
Generated source provenance marker lines 54–61
54:87… or.
55 body: Vec<u8>,
56 },
57 /// Error generated by the `http` crate.
58 Http(http::Error),
59 /// IO Error
60 Io(io::Error),
61 /// Invalid ba …
imports ErrorKind::* lines 114–118
114:24… ut fmt::Formatter) -> fmt::Result {
115 use ErrorKind::*;
116
117 match *self.0 {
118 ConnectNotSupported => write!(w, "CONNECT is not supporte …

Keyboard shortcuts on this page: j for the next sample, k for the previous one, x to go back to the feed, d to download the original bytes, r to re-queue the sample for analysis.