From 73b4c03b5502edd0b9922ce88964d1be55978eec Mon Sep 17 00:00:00 2001 From: walfie Date: Wed, 14 Feb 2018 00:00:09 -0500 Subject: [PATCH] Fix typos (#223) --- src/client.rs | 8 ++++---- src/frame/mod.rs | 2 +- src/proto/streams/prioritize.rs | 10 +++++----- src/proto/streams/recv.rs | 2 +- src/server.rs | 6 +++--- src/share.rs | 8 ++++---- 6 files changed, 18 insertions(+), 18 deletions(-) diff --git a/src/client.rs b/src/client.rs index 467e2f9..97539fa 100644 --- a/src/client.rs +++ b/src/client.rs @@ -17,7 +17,7 @@ //! [`handshake`] uses default configuration values. There are a number of //! settings that can be changed by using [`Builder`] instead. //! -//! Once the the handshake future completes, the caller is provided with a +//! Once the handshake future completes, the caller is provided with a //! [`Connection`] instance and a [`SendRequest`] instance. The [`Connection`] //! instance is used to drive the connection (see [Managing the connection]). //! The [`SendRequest`] instance is used to initialize new streams (see [Making @@ -840,7 +840,7 @@ impl Builder { /// /// When a stream is explicitly reset by either calling /// [`SendResponse::send_reset`] or by dropping a [`SendResponse`] instance - /// before completing te stream, the HTTP/2.0 specification requires that + /// before completing the stream, the HTTP/2.0 specification requires that /// any further frames received for that stream must be ignored for "some /// time". /// @@ -888,7 +888,7 @@ impl Builder { /// /// When a stream is explicitly reset by either calling /// [`SendResponse::send_reset`] or by dropping a [`SendResponse`] instance - /// before completing te stream, the HTTP/2.0 specification requires that + /// before completing the stream, the HTTP/2.0 specification requires that /// any further frames received for that stream must be ignored for "some /// time". /// @@ -937,7 +937,7 @@ impl Builder { /// /// This value is included in the initial SETTINGS handshake. When set, the /// server MUST NOT send a push promise. Setting this value to value to - /// false in the intial SETTINGS handshake guarantees that the remote server + /// false in the initial SETTINGS handshake guarantees that the remote server /// will never send a push promise. /// /// This setting can be changed during the life of a single HTTP/2.0 diff --git a/src/frame/mod.rs b/src/frame/mod.rs index 0799501..36fcafa 100644 --- a/src/frame/mod.rs +++ b/src/frame/mod.rs @@ -151,7 +151,7 @@ pub enum Error { /// An invalid stream dependency ID was provided /// - /// This is returend if a HEADERS or PRIORITY frame is received with an + /// This is returned if a HEADERS or PRIORITY frame is received with an /// invalid stream identifier. InvalidDependencyId, diff --git a/src/proto/streams/prioritize.rs b/src/proto/streams/prioritize.rs index 0d9919d..ce0d847 100644 --- a/src/proto/streams/prioritize.rs +++ b/src/proto/streams/prioritize.rs @@ -13,7 +13,7 @@ use std::io; /// # Warning /// -/// Queued streans are ordered by stream ID, as we need to ensure that +/// Queued streams are ordered by stream ID, as we need to ensure that /// lower-numbered streams are sent headers before higher-numbered ones. /// This is because "idle" stream IDs – those which have been initiated but /// have yet to receive frames – will be implicitly closed on receipt of a @@ -164,7 +164,7 @@ impl Prioritize { // queued data), it gets sent out immediately even if there is no // available send window. // - // Sending out zero length data frames can be done to singal + // Sending out zero length data frames can be done to signal // end-of-stream. // if stream.send_flow.available() > 0 || stream.buffered_send_data == 0 { @@ -173,7 +173,7 @@ impl Prioritize { self.queue_frame(frame.into(), buffer, stream, task); } else { // The stream has no capacity to send the frame now, save it but - // don't notify the conneciton task. Once additional capacity + // don't notify the connection task. Once additional capacity // becomes available, the frame will be flushed. stream .pending_send @@ -380,7 +380,7 @@ impl Prioritize { if stream.send_flow.available() < stream.requested_send_capacity { if stream.send_flow.has_unavailable() { // The stream requires additional capacity and the stream's - // window has availablel capacity, but the connection window + // window has available capacity, but the connection window // does not. // // In this case, the stream needs to be queued up for when the @@ -512,7 +512,7 @@ impl Prioritize { } /// Push the frame to the front of the stream's deque, scheduling the - /// steream if needed. + /// stream if needed. fn push_back_frame(&mut self, frame: Frame, buffer: &mut Buffer>, diff --git a/src/proto/streams/recv.rs b/src/proto/streams/recv.rs index 96391d5..28a263e 100644 --- a/src/proto/streams/recv.rs +++ b/src/proto/streams/recv.rs @@ -341,7 +341,7 @@ impl Recv { /// /// Setting a target means that we will try to tell the peer about /// WINDOW_UPDATEs so the peer knows it has about `target` window to use - /// for the whole conection. + /// for the whole connection. /// /// The `task` is an optional parked task for the `Connection` that might /// be blocked on needing more window capacity. diff --git a/src/server.rs b/src/server.rs index be49e39..7a7752c 100644 --- a/src/server.rs +++ b/src/server.rs @@ -16,7 +16,7 @@ //! completes once the handshake process is performed and HTTP/2.0 streams may //! be received. //! -//! [`handshake`] uses default configuration values. THere are a number of +//! [`handshake`] uses default configuration values. There are a number of //! settings that can be changed by using [`Builder`] instead. //! //! # Inbound streams @@ -679,7 +679,7 @@ impl Builder { /// /// When a stream is explicitly reset by either calling /// [`SendResponse::send_reset`] or by dropping a [`SendResponse`] instance - /// before completing te stream, the HTTP/2.0 specification requires that + /// before completing the stream, the HTTP/2.0 specification requires that /// any further frames received for that stream must be ignored for "some /// time". /// @@ -727,7 +727,7 @@ impl Builder { /// /// When a stream is explicitly reset by either calling /// [`SendResponse::send_reset`] or by dropping a [`SendResponse`] instance - /// before completing te stream, the HTTP/2.0 specification requires that + /// before completing the stream, the HTTP/2.0 specification requires that /// any further frames received for that stream must be ignored for "some /// time". /// diff --git a/src/share.rs b/src/share.rs index 5302b94..b50625b 100644 --- a/src/share.rs +++ b/src/share.rs @@ -46,7 +46,7 @@ use std::fmt; /// The implications for sending data are that the caller **should** ensure that /// both the stream and the connection has available window capacity before /// loading the data to send into memory. The `SendStream` instance provides the -/// necessary APIs to perform this logic. This, however, is not an oblication. +/// necessary APIs to perform this logic. This, however, is not an obligation. /// If the caller attempts to send data on a stream when there is no available /// window capacity, the library will buffer the data until capacity becomes /// available, at which point the buffer will be flushed to the connection. @@ -220,7 +220,7 @@ impl SendStream { /// ``` /// /// After the second call to `reserve_capacity`, the *total* requested - /// capcaity will be 0, i.e. there is no requested capacity for the stream. + /// capacity will be 0, i.e. there is no requested capacity for the stream. /// /// If `reserve_capacity` is called with a lower value than the amount of /// capacity **currently** assigned to the stream, this capacity will be @@ -246,7 +246,7 @@ impl SendStream { /// # } /// ``` /// - /// See [Flow contro](struct.SendStream.html#flow-control) for an overview + /// See [Flow control](struct.SendStream.html#flow-control) for an overview /// of how send flow control works. pub fn reserve_capacity(&mut self, capacity: usize) { // TODO: Check for overflow @@ -312,7 +312,7 @@ impl SendStream { /// Resets the stream. /// /// This cancels the request / response exchange. If the response has not - /// yet been received, the associatd `ResponseFuture` will return an + /// yet been received, the associated `ResponseFuture` will return an /// [`Error`] to reflect the canceled exchange. /// /// [`Error`]: struct.Error.html