Skip to content

Commit

Permalink
Rename set_broadast() to set_broadcast().
Browse files Browse the repository at this point in the history
  • Loading branch information
jbcrail authored and alexcrichton committed Jul 3, 2014
1 parent e3fa23b commit 4a6fcc5
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/libstd/io/net/udp.rs
Expand Up @@ -165,14 +165,20 @@ impl UdpSocket {

/// Sets the broadcast flag on or off
#[experimental]
pub fn set_broadast(&mut self, broadcast: bool) -> IoResult<()> {
pub fn set_broadcast(&mut self, broadcast: bool) -> IoResult<()> {
if broadcast {
self.obj.hear_broadcasts()
} else {
self.obj.ignore_broadcasts()
}.map_err(IoError::from_rtio_error)
}

/// Sets the broadcast flag on or off
#[deprecated="renamed to `set_broadcast`"]
pub fn set_broadast(&mut self, broadcast: bool) -> IoResult<()> {
self.set_broadcast(broadcast)
}

/// Sets the read/write timeout for this socket.
///
/// For more information, see `TcpStream::set_timeout`
Expand Down

0 comments on commit 4a6fcc5

Please sign in to comment.