author Sebastian Hengst <>
Tue, 26 Mar 2019 21:38:23 +0100
changeset 466339 07595d5c98d2137f0a7dd4334b0c315988b8642e
parent 448947 6f3709b3878117466168c40affa7bca0b60cf75b
permissions -rw-r--r--
Backed out changeset f9c865b93ecd (bug 1533777) because it landed with the wrong patch author. a=backout

/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this file,
 * You can obtain one at */

#ifndef nricestunaddr_h__
#define nricestunaddr_h__

#include "nsError.h"  // for nsresult

typedef struct nr_local_addr_ nr_local_addr;

namespace mozilla {

class NrIceStunAddr {
  NrIceStunAddr();  // needed for IPC deserialization
  explicit NrIceStunAddr(const nr_local_addr* addr);
  NrIceStunAddr(const NrIceStunAddr& rhs);


  const nr_local_addr& localAddr() const { return *localAddr_; }

  // serialization/deserialization helper functions for use
  // in media/mtransport/ipc/NrIceStunAddrMessagUtils.h
  size_t SerializationBufferSize() const;
  nsresult Serialize(char* buffer, size_t buffer_size) const;
  nsresult Deserialize(const char* buffer, size_t buffer_size);

  nr_local_addr* localAddr_;

}  // namespace mozilla

#endif  // nricestunaddr_h__