remove as_ptr()
Signed-off-by: Walker Crouse <Walker.Crouse@coop.co.uk>
This commit is contained in:
parent
35e5d00bb4
commit
97ad8097e0
@ -100,7 +100,7 @@ impl BonjourMdnsService {
|
||||
let txt_record = self
|
||||
.txt_record
|
||||
.as_ref()
|
||||
.map(|t| t.as_ptr())
|
||||
.map(|t| t.0.get_bytes_ptr())
|
||||
.unwrap_or_null();
|
||||
|
||||
self.service.lock().unwrap().register_service(
|
||||
|
@ -8,7 +8,7 @@ use std::{mem, ptr};
|
||||
|
||||
/// Interface for interfacting with Bonjour's TXT record capabilities.
|
||||
#[derive(Debug)]
|
||||
pub struct BonjourTxtRecord(ManagedTXTRecordRef);
|
||||
pub struct BonjourTxtRecord(pub(crate) ManagedTXTRecordRef);
|
||||
|
||||
impl BonjourTxtRecord {
|
||||
/// Constructs a new TXT recoord
|
||||
@ -87,11 +87,6 @@ impl BonjourTxtRecord {
|
||||
Box::new(Values(Iter::new(self)))
|
||||
}
|
||||
|
||||
/// Returns a raw pointer to the underlying TXT data.
|
||||
pub fn as_ptr(&self) -> *const c_void {
|
||||
self.0.get_bytes_ptr()
|
||||
}
|
||||
|
||||
/// Returns the size of the raw bytes in the TXT record.
|
||||
pub fn size(&self) -> u16 {
|
||||
self.0.get_length()
|
||||
|
Loading…
Reference in New Issue
Block a user