OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/local_discovery/service_discovery_client_mdns.h" | 5 #include "chrome/browser/local_discovery/service_discovery_client_mdns.h" |
6 | 6 |
| 7 #include <stddef.h> |
| 8 |
7 #include <vector> | 9 #include <vector> |
8 | 10 |
9 #include "base/location.h" | 11 #include "base/location.h" |
| 12 #include "base/macros.h" |
10 #include "base/memory/scoped_ptr.h" | 13 #include "base/memory/scoped_ptr.h" |
11 #include "base/metrics/histogram.h" | 14 #include "base/metrics/histogram.h" |
12 #include "base/single_thread_task_runner.h" | 15 #include "base/single_thread_task_runner.h" |
13 #include "base/thread_task_runner_handle.h" | 16 #include "base/thread_task_runner_handle.h" |
14 #include "chrome/common/local_discovery/service_discovery_client_impl.h" | 17 #include "chrome/common/local_discovery/service_discovery_client_impl.h" |
15 #include "content/public/browser/browser_thread.h" | 18 #include "content/public/browser/browser_thread.h" |
16 #include "net/dns/mdns_client.h" | 19 #include "net/dns/mdns_client.h" |
17 #include "net/udp/datagram_server_socket.h" | 20 #include "net/udp/datagram_server_socket.h" |
18 | 21 |
19 namespace local_discovery { | 22 namespace local_discovery { |
(...skipping 416 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
436 OnBeforeMdnsDestroy(); | 439 OnBeforeMdnsDestroy(); |
437 // After calling |Proxy::OnMdnsDestroy| all references to client_ and mdns_ | 440 // After calling |Proxy::OnMdnsDestroy| all references to client_ and mdns_ |
438 // should be destroyed. | 441 // should be destroyed. |
439 if (client_) | 442 if (client_) |
440 mdns_runner_->DeleteSoon(FROM_HERE, client_.release()); | 443 mdns_runner_->DeleteSoon(FROM_HERE, client_.release()); |
441 if (mdns_) | 444 if (mdns_) |
442 mdns_runner_->DeleteSoon(FROM_HERE, mdns_.release()); | 445 mdns_runner_->DeleteSoon(FROM_HERE, mdns_.release()); |
443 } | 446 } |
444 | 447 |
445 } // namespace local_discovery | 448 } // namespace local_discovery |
OLD | NEW |