Skip to content

Commit

Permalink
Compiles and links.
Browse files Browse the repository at this point in the history
  • Loading branch information
docfaraday committed Sep 18, 2014
1 parent 7fc4592 commit 1f9dd80
Show file tree
Hide file tree
Showing 8 changed files with 15 additions and 14 deletions.
3 changes: 1 addition & 2 deletions media/webrtc/signaling/src/sdp/Sdp.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class SdpMediaSection;
class Sdp
{
public:
Sdp();
Sdp() {};

virtual SdpOrigin GetOrigin() const = 0;
virtual std::string GetSessionName() const = 0;
Expand All @@ -39,7 +39,6 @@ class Sdp
virtual const SdpMediaSection &GetMediaSection(uint16_t level) const = 0;
virtual SdpMediaSection &GetMediaSection(uint16_t level) = 0;

protected:
virtual ~Sdp() {};
};

Expand Down
4 changes: 1 addition & 3 deletions media/webrtc/signaling/src/sdp/SdpAttribute.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ class SdpAttribute
public:
SdpAttribute(sdp::AttributeType type, std::string typeName) :
mType(type), mTypeName(typeName) {}
virtual ~SdpAttribute() {}

virtual sdp::AttributeType GetType()
{
Expand All @@ -30,9 +31,6 @@ class SdpAttribute
return mTypeName;
}

protected:
virtual ~SdpAttribute() {}

private:
sdp::AttributeType mType;
std::string mTypeName;
Expand Down
2 changes: 1 addition & 1 deletion media/webrtc/signaling/src/sdp/SipccSdp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ SipccSdp::GetSessionName() const {
}

Maybe<std::string>
SipccSdp::GetBandwidth(std::string type) const {
SipccSdp::GetBandwidth(const std::string& type) const {
return Maybe<std::string>();
}

Expand Down
4 changes: 3 additions & 1 deletion media/webrtc/signaling/src/sdp/SipccSdp.h
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,9 @@ class SipccSdp MOZ_FINAL : public Sdp
virtual SdpMediaSection &GetMediaSection(uint16_t level) MOZ_OVERRIDE;

private:
SipccSdp(sdp_t* sdp) : mSdp(sdp) {}
explicit SipccSdp(sdp_t* sdp) :
mSdp(sdp),
mAttributeList(sdp, 0) {}

void Load();

Expand Down
1 change: 1 addition & 0 deletions media/webrtc/signaling/src/sdp/SipccSdpAttributeList.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ class SipccSdpMediaSection;
class SipccSdpAttributeList : public SdpAttributeList
{
friend class SipccSdpMediaSection;
friend class SipccSdp;
public:
virtual unsigned int CountAttributes(sdp::AttributeType type) const MOZ_OVERRIDE;
virtual bool HasAttribute(sdp::AttributeType type) const MOZ_OVERRIDE;
Expand Down
3 changes: 2 additions & 1 deletion media/webrtc/signaling/src/sdp/SipccSdpMediaSection.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ class SipccSdpMediaSection MOZ_FINAL : public SdpMediaSection
{
friend class SipccSdp;
public:
~SipccSdpMediaSection() {}

virtual sdp::MediaType
GetMediaType() const MOZ_OVERRIDE
{
Expand All @@ -46,7 +48,6 @@ class SipccSdpMediaSection MOZ_FINAL : public SdpMediaSection
mLevel(level),
mAttributes(sdp, level),
mConnection(sdp::kInternet, sdp::kIPv4, "0.0.0.0") {}
~SipccSdpMediaSection() {}

void Load();

Expand Down
4 changes: 2 additions & 2 deletions media/webrtc/signaling/src/sdp/SipccSdpParser.h
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,11 @@ class SipccSdpParser
* Returns a reference to the list of parse errors.
* This gets cleared out when you call Parse.
*/
const std::vector<std::pair<uint32_t, const std::string> >&
const std::vector<std::pair<uint32_t, std::string> >&
GetParseErrors() const { return mErrors; }

private:
std::vector<std::pair<uint32_t, const std::string> > mErrors;
std::vector<std::pair<uint32_t, std::string> > mErrors;
};

} // namespace mozilla
Expand Down
8 changes: 4 additions & 4 deletions media/webrtc/signaling/test/sdp_unittests.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -105,13 +105,13 @@ class SdpTest : public ::testing::Test {
if (!sdp_ptr_) {
sdp_free_description(sdp_ptr_);
}
sdp_ptr_ = sdp_init_description("BogusPeerConnectionId", config_p_);
sdp_ptr_ = sdp_init_description(config_p_);
}

void ParseSdp(const std::string &sdp_str) {
char *bufp = const_cast<char *>(sdp_str.data());
const char *buf = sdp_str.data();
ResetSdp();
ASSERT_EQ(sdp_parse(sdp_ptr_, &bufp, sdp_str.size()), SDP_SUCCESS);
ASSERT_EQ(sdp_parse(sdp_ptr_, buf, sdp_str.size()), SDP_SUCCESS);
}

void InitLocalSdp() {
Expand Down Expand Up @@ -246,7 +246,7 @@ class SdpTest : public ::testing::Test {

protected:
int final_level_;
void *config_p_;
sdp_conf_options_t *config_p_;
sdp_t *sdp_ptr_;
};

Expand Down

0 comments on commit 1f9dd80

Please sign in to comment.