Skip to content

Commit db902bc

Browse files
committed
Add the code of the tracking issue
1 parent cc085e9 commit db902bc

File tree

4 files changed

+36
-36
lines changed

4 files changed

+36
-36
lines changed

library/std/src/sys/unix/ext/net/ancillary.rs

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@ impl<'a, T> Iterator for AncillaryDataIter<'a, T> {
167167

168168
/// Unix credential.
169169
#[cfg(any(doc, target_os = "android", target_os = "emscripten", target_os = "linux",))]
170-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
170+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
171171
#[derive(Clone)]
172172
pub struct SocketCred(libc::ucred);
173173

@@ -176,43 +176,43 @@ impl SocketCred {
176176
/// Create a Unix credential struct.
177177
///
178178
/// PID, UID and GID is set to 0.
179-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
179+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
180180
pub fn new() -> SocketCred {
181181
SocketCred(libc::ucred { pid: 0, uid: 0, gid: 0 })
182182
}
183183

184184
/// Set the PID.
185-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
185+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
186186
pub fn set_pid(&mut self, pid: pid_t) {
187187
self.0.pid = pid;
188188
}
189189

190190
/// Get the current PID.
191-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
191+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
192192
pub fn get_pid(&self) -> pid_t {
193193
self.0.pid
194194
}
195195

196196
/// Set the UID.
197-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
197+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
198198
pub fn set_uid(&mut self, uid: uid_t) {
199199
self.0.uid = uid;
200200
}
201201

202202
/// Get the current UID.
203-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
203+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
204204
pub fn get_uid(&self) -> uid_t {
205205
self.0.uid
206206
}
207207

208208
/// Set the GID.
209-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
209+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
210210
pub fn set_gid(&mut self, gid: gid_t) {
211211
self.0.gid = gid;
212212
}
213213

214214
/// Get the current GID.
215-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
215+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
216216
pub fn get_gid(&self) -> gid_t {
217217
self.0.gid
218218
}
@@ -221,10 +221,10 @@ impl SocketCred {
221221
/// This control message contains file descriptors.
222222
///
223223
/// The level is equal to `SOL_SOCKET` and the type is equal to `SCM_RIGHTS`.
224-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
224+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
225225
pub struct ScmRights<'a>(AncillaryDataIter<'a, RawFd>);
226226

227-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
227+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
228228
impl<'a> Iterator for ScmRights<'a> {
229229
type Item = RawFd;
230230

@@ -237,11 +237,11 @@ impl<'a> Iterator for ScmRights<'a> {
237237
///
238238
/// The level is equal to `SOL_SOCKET` and the type is equal to `SCM_CREDENTIALS` or `SCM_CREDS`.
239239
#[cfg(any(doc, target_os = "android", target_os = "emscripten", target_os = "linux",))]
240-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
240+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
241241
pub struct ScmCredentials<'a>(AncillaryDataIter<'a, libc::ucred>);
242242

243243
#[cfg(any(doc, target_os = "android", target_os = "emscripten", target_os = "linux",))]
244-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
244+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
245245
impl<'a> Iterator for ScmCredentials<'a> {
246246
type Item = SocketCred;
247247

@@ -253,13 +253,13 @@ impl<'a> Iterator for ScmCredentials<'a> {
253253
/// The error type which is returned from parsing the type a control message.
254254
#[non_exhaustive]
255255
#[derive(Debug)]
256-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
256+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
257257
pub enum AncillaryError {
258258
Unknown { cmsg_level: i32, cmsg_type: i32 },
259259
}
260260

261261
/// This enum represent one control message of variable type.
262-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
262+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
263263
pub enum AncillaryData<'a> {
264264
ScmRights(ScmRights<'a>),
265265
#[cfg(any(doc, target_os = "android", target_os = "emscripten", target_os = "linux",))]
@@ -321,13 +321,13 @@ impl<'a> AncillaryData<'a> {
321321
}
322322

323323
/// This struct is used to iterate through the control messages.
324-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
324+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
325325
pub struct Messages<'a> {
326326
buffer: &'a [u8],
327327
current: Option<&'a libc::cmsghdr>,
328328
}
329329

330-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
330+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
331331
impl<'a> Iterator for Messages<'a> {
332332
type Item = Result<AncillaryData<'a>, AncillaryError>;
333333

@@ -386,7 +386,7 @@ impl<'a> Iterator for Messages<'a> {
386386
/// Ok(())
387387
/// }
388388
/// ```
389-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
389+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
390390
#[derive(Debug)]
391391
pub struct SocketAncillary<'a> {
392392
buffer: &'a mut [u8],
@@ -406,25 +406,25 @@ impl<'a> SocketAncillary<'a> {
406406
/// let mut ancillary_buffer = [0; 128];
407407
/// let mut ancillary = SocketAncillary::new(&mut ancillary_buffer[..]);
408408
/// ```
409-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
409+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
410410
pub fn new(buffer: &'a mut [u8]) -> Self {
411411
SocketAncillary { buffer, length: 0, truncated: false }
412412
}
413413

414414
/// Returns the capacity of the buffer.
415-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
415+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
416416
pub fn capacity(&self) -> usize {
417417
self.buffer.len()
418418
}
419419

420420
/// Returns the number of used bytes.
421-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
421+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
422422
pub fn len(&self) -> usize {
423423
self.length
424424
}
425425

426426
/// Returns the iterator of the control messages.
427-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
427+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
428428
pub fn messages(&self) -> Messages<'_> {
429429
Messages { buffer: &self.buffer[..self.length], current: None }
430430
}
@@ -452,7 +452,7 @@ impl<'a> SocketAncillary<'a> {
452452
/// Ok(())
453453
/// }
454454
/// ```
455-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
455+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
456456
pub fn truncated(&self) -> bool {
457457
self.truncated
458458
}
@@ -485,7 +485,7 @@ impl<'a> SocketAncillary<'a> {
485485
/// Ok(())
486486
/// }
487487
/// ```
488-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
488+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
489489
pub fn add_fds(&mut self, fds: &[RawFd]) -> bool {
490490
self.truncated = false;
491491
add_to_ancillary_data(
@@ -505,7 +505,7 @@ impl<'a> SocketAncillary<'a> {
505505
/// and type `SCM_CREDENTIALS` or `SCM_CREDS`.
506506
///
507507
#[cfg(any(doc, target_os = "android", target_os = "emscripten", target_os = "linux",))]
508-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
508+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
509509
pub fn add_creds(&mut self, creds: &[SocketCred]) -> bool {
510510
self.truncated = false;
511511
add_to_ancillary_data(
@@ -559,7 +559,7 @@ impl<'a> SocketAncillary<'a> {
559559
/// Ok(())
560560
/// }
561561
/// ```
562-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
562+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
563563
pub fn clear(&mut self) {
564564
self.length = 0;
565565
self.truncated = false;

library/std/src/sys/unix/ext/net/datagram.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -378,7 +378,7 @@ impl UnixDatagram {
378378
target_os = "solaris",
379379
target_env = "uclibc",
380380
))]
381-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
381+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
382382
pub fn recv_vectored_with_ancillary_from(
383383
&self,
384384
bufs: &mut [IoSliceMut<'_>],
@@ -442,7 +442,7 @@ impl UnixDatagram {
442442
target_os = "solaris",
443443
target_env = "uclibc",
444444
))]
445-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
445+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
446446
pub fn recv_vectored_with_ancillary(
447447
&self,
448448
bufs: &mut [IoSliceMut<'_>],
@@ -539,7 +539,7 @@ impl UnixDatagram {
539539
/// Ok(())
540540
/// }
541541
/// ```
542-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
542+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
543543
pub fn send_vectored_with_ancillary_to<P: AsRef<Path>>(
544544
&self,
545545
bufs: &mut [IoSliceMut<'_>],
@@ -578,7 +578,7 @@ impl UnixDatagram {
578578
/// Ok(())
579579
/// }
580580
/// ```
581-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
581+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
582582
pub fn send_vectored_with_ancillary(
583583
&self,
584584
bufs: &mut [IoSliceMut<'_>],
@@ -765,7 +765,7 @@ impl UnixDatagram {
765765
target_os = "openbsd",
766766
target_env = "uclibc",
767767
))]
768-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
768+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
769769
pub fn set_passcred(&self, passcred: bool) -> io::Result<()> {
770770
self.0.set_passcred(passcred)
771771
}
@@ -790,7 +790,7 @@ impl UnixDatagram {
790790
target_os = "openbsd",
791791
target_env = "uclibc",
792792
))]
793-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
793+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
794794
pub fn passcred(&self) -> io::Result<bool> {
795795
self.0.passcred()
796796
}

library/std/src/sys/unix/ext/net/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ pub use self::addr::*;
6262
target_os = "solaris",
6363
target_env = "uclibc",
6464
))]
65-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
65+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
6666
pub use self::ancillary::*;
6767
#[stable(feature = "unix_socket", since = "1.10.0")]
6868
pub use self::datagram::*;

library/std/src/sys/unix/ext/net/stream.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -396,7 +396,7 @@ impl UnixStream {
396396
target_os = "openbsd",
397397
target_env = "uclibc",
398398
))]
399-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
399+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
400400
pub fn set_passcred(&self, passcred: bool) -> io::Result<()> {
401401
self.0.set_passcred(passcred)
402402
}
@@ -421,7 +421,7 @@ impl UnixStream {
421421
target_os = "openbsd",
422422
target_env = "uclibc",
423423
))]
424-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
424+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
425425
pub fn passcred(&self) -> io::Result<bool> {
426426
self.0.passcred()
427427
}
@@ -550,7 +550,7 @@ impl UnixStream {
550550
target_os = "solaris",
551551
target_env = "uclibc",
552552
))]
553-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
553+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
554554
pub fn recv_vectored_with_ancillary(
555555
&self,
556556
bufs: &mut [IoSliceMut<'_>],
@@ -606,7 +606,7 @@ impl UnixStream {
606606
target_os = "solaris",
607607
target_env = "uclibc",
608608
))]
609-
#[unstable(feature = "unix_socket_ancillary_data", issue = "none")]
609+
#[unstable(feature = "unix_socket_ancillary_data", issue = "76915")]
610610
pub fn send_vectored_with_ancillary(
611611
&self,
612612
bufs: &mut [IoSliceMut<'_>],

0 commit comments

Comments
 (0)