Merge lp:~morphis/aethercast/small-fixes into lp:aethercast

Proposed by Simon Fels
Status: Merged
Approved by: Alfonso Sanchez-Beato
Approved revision: 150
Merged at revision: 152
Proposed branch: lp:~morphis/aethercast/small-fixes
Merge into: lp:aethercast
Diff against target: 33 lines (+4/-5)
2 files modified
src/ac/service.cpp (+3/-3)
src/ac/sourceclient.cpp (+1/-2)
To merge this branch: bzr merge lp:~morphis/aethercast/small-fixes
Reviewer Review Type Date Requested Status
Konrad Zapałowicz (community) code Approve
Matteo Croce (community) Approve
Alfonso Sanchez-Beato Approve
Review via email: mp+300044@code.launchpad.net

Commit message

Fix RTSP debugging and device state update reporting

Due to previous search&replace operations the environment variable we are using to enable RTSP debugging was corrupted and is now correctly named AETHERCAST_RTSP_DEBUG. Furthermore we were only reporting device state updates for the current device but should really report them for every device regardless if its the current one or not.

To post a comment you must log in.
Revision history for this message
Alfonso Sanchez-Beato (alfonsosanchezbeato) wrote :

LGTM

review: Approve
Revision history for this message
Matteo Croce (teknoraver) :
review: Approve
lp:~morphis/aethercast/small-fixes updated
151. By Simon Fels

Use commong ac::utils::IsEnvSet

152. By Simon Fels

Use correct namespace

Revision history for this message
Konrad Zapałowicz (kzapalowicz) wrote :

LGTM

review: Approve (code)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/ac/service.cpp'
2--- src/ac/service.cpp 2016-06-07 08:21:20 +0000
3+++ src/ac/service.cpp 2016-07-14 08:49:14 +0000
4@@ -385,13 +385,13 @@
5 device->Address(),
6 ac::NetworkDevice::StateToStr(device->State()));
7
8+ if (auto sp = delegate_.lock())
9+ sp->OnDeviceChanged(device);
10+
11 if (device != current_device_)
12 return;
13
14 AdvanceState(device->State());
15-
16- if (auto sp = delegate_.lock())
17- sp->OnDeviceChanged(device);
18 }
19
20 void Service::OnDeviceChanged(const NetworkDevice::Ptr &device) {
21
22=== modified file 'src/ac/sourceclient.cpp'
23--- src/ac/sourceclient.cpp 2016-06-07 08:21:20 +0000
24+++ src/ac/sourceclient.cpp 2016-07-14 08:49:14 +0000
25@@ -66,8 +66,7 @@
26 }
27
28 void SourceClient::DumpRtsp(const std::string &prefix, const std::string &data) {
29- static bool enabled = getenv("MIRACAST_RTSP_AC_DEBUG") != nullptr;
30-
31+ static bool enabled = Utils::IsEnvSet("AETHERCAST_RTSP_DEBUG");
32 if (!enabled)
33 return;
34

Subscribers

People subscribed via source and target branches

to all changes: