Skip to content

Commit

Permalink
Allow some broken links
Browse files Browse the repository at this point in the history
It's too much of a hassle to fix these on all platforms, so they can
simply be displayed as text, without a link.
  • Loading branch information
Thomasdezeeuw committed Feb 26, 2023
1 parent bf8f5ba commit b632eb4
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 3 deletions.
12 changes: 9 additions & 3 deletions src/socket.rs
Original file line number Diff line number Diff line change
Expand Up @@ -425,6 +425,7 @@ impl Socket {
///
/// [`recv`]: Socket::recv
/// [`out_of_band_inline`]: Socket::out_of_band_inline
#[cfg_attr(target_os = "redox", allow(rustdoc::broken_intra_doc_links))]
pub fn recv_out_of_band(&self, buf: &mut [MaybeUninit<u8>]) -> io::Result<usize> {
self.recv_with_flags(buf, sys::MSG_OOB)
}
Expand Down Expand Up @@ -640,7 +641,7 @@ impl Socket {
/// Identical to [`send`] but allows for specification of arbitrary flags to the underlying
/// `send` call.
///
/// [`send`]: #method.send
/// [`send`]: Socket::send
pub fn send_with_flags(&self, buf: &[u8], flags: c_int) -> io::Result<usize> {
sys::send(self.as_raw(), buf, flags)
}
Expand Down Expand Up @@ -672,8 +673,9 @@ impl Socket {
///
/// For more information, see [`send`], [`out_of_band_inline`].
///
/// [`send`]: #method.send
/// [`out_of_band_inline`]: #method.out_of_band_inline
/// [`send`]: Socket::send
/// [`out_of_band_inline`]: Socket::out_of_band_inline
#[cfg_attr(target_os = "redox", allow(rustdoc::broken_intra_doc_links))]
pub fn send_out_of_band(&self, buf: &[u8]) -> io::Result<usize> {
self.send_with_flags(buf, sys::MSG_OOB)
}
Expand Down Expand Up @@ -1103,6 +1105,10 @@ impl Socket {
/// [raw(7)]: https://man7.org/linux/man-pages/man7/raw.7.html
/// [`IP_TTL`]: Socket::set_ttl
/// [`IP_TOS`]: Socket::set_tos
#[cfg_attr(
any(target_os = "illumos", target_os = "solaris"),
allow(rustdoc::broken_intra_doc_links)
)]
#[cfg(all(feature = "all", not(target_os = "redox")))]
#[cfg_attr(docsrs, doc(cfg(all(feature = "all", not(target_os = "redox")))))]
pub fn set_header_included(&self, included: bool) -> io::Result<()> {
Expand Down
9 changes: 9 additions & 0 deletions src/sys/unix.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1221,6 +1221,15 @@ impl crate::Socket {
/// # Notes
///
/// On supported platforms you can use [`Type::cloexec`].
#[cfg_attr(
any(
target_os = "ios",
target_os = "macos",
target_os = "tvos",
target_os = "watchos"
),
allow(rustdoc::broken_intra_doc_links)
)]
#[cfg(feature = "all")]
#[cfg_attr(docsrs, doc(cfg(all(feature = "all", unix))))]
pub fn set_cloexec(&self, close_on_exec: bool) -> io::Result<()> {
Expand Down

0 comments on commit b632eb4

Please sign in to comment.