Skip to content

Commit d0dc697

Browse files
author
Eric Reed
committed
removed unecessary method
1 parent 34b1135 commit d0dc697

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/libstd/rt/io/net/udp.rs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,12 +19,10 @@ use rt::local::Local;
1919
pub struct UdpSocket(~RtioUdpSocketObject);
2020

2121
impl UdpSocket {
22-
fn new(s: ~RtioUdpSocketObject) -> UdpSocket { UdpSocket(s) }
23-
2422
pub fn bind(addr: IpAddr) -> Option<UdpSocket> {
2523
let socket = unsafe { (*Local::unsafe_borrow::<IoFactoryObject>()).udp_bind(addr) };
2624
match socket {
27-
Ok(s) => Some(UdpSocket::new(s)),
25+
Ok(s) => Some(UdpSocket(s)),
2826
Err(ioerr) => {
2927
io_error::cond.raise(ioerr);
3028
None

0 commit comments

Comments
 (0)