diff options
Diffstat (limited to 'src/client/linux/crash_generation')
3 files changed, 16 insertions, 11 deletions
diff --git a/src/client/linux/crash_generation/crash_generation_client.cc b/src/client/linux/crash_generation/crash_generation_client.cc index 5a8c6b4c..020c6146 100644 --- a/src/client/linux/crash_generation/crash_generation_client.cc +++ b/src/client/linux/crash_generation/crash_generation_client.cc @@ -26,6 +26,10 @@ // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +#ifdef HAVE_CONFIG_H +#include <config.h> // Must come first +#endif + #include "client/linux/crash_generation/crash_generation_client.h" #include <stdio.h> @@ -45,9 +49,11 @@ namespace { class CrashGenerationClientImpl : public CrashGenerationClient { public: explicit CrashGenerationClientImpl(int server_fd) : server_fd_(server_fd) {} - virtual ~CrashGenerationClientImpl() {} + CrashGenerationClientImpl(const CrashGenerationClientImpl&) = delete; + void operator=(const CrashGenerationClientImpl&) = delete; + ~CrashGenerationClientImpl() override = default; - virtual bool RequestDump(const void* blob, size_t blob_size) { + bool RequestDump(const void* blob, size_t blob_size) override { int fds[2]; if (sys_pipe(fds) < 0) return false; @@ -88,8 +94,6 @@ class CrashGenerationClientImpl : public CrashGenerationClient { private: int server_fd_; - - DISALLOW_COPY_AND_ASSIGN(CrashGenerationClientImpl); }; } // namespace diff --git a/src/client/linux/crash_generation/crash_generation_client.h b/src/client/linux/crash_generation/crash_generation_client.h index 915b5700..1e4a7a5e 100644 --- a/src/client/linux/crash_generation/crash_generation_client.h +++ b/src/client/linux/crash_generation/crash_generation_client.h @@ -29,8 +29,6 @@ #ifndef CLIENT_LINUX_CRASH_GENERATION_CRASH_GENERATION_CLIENT_H_ #define CLIENT_LINUX_CRASH_GENERATION_CRASH_GENERATION_CLIENT_H_ -#include "common/basictypes.h" - #include <stddef.h> namespace google_breakpad { @@ -41,8 +39,10 @@ namespace google_breakpad { // via a remote process. class CrashGenerationClient { public: - CrashGenerationClient() {} - virtual ~CrashGenerationClient() {} + CrashGenerationClient() = default; + CrashGenerationClient(const CrashGenerationClient&) = delete; + void operator=(const CrashGenerationClient&) = delete; + virtual ~CrashGenerationClient() = default; // Request the crash server to generate a dump. |blob| is an opaque // CrashContext pointer from exception_handler.h. @@ -54,9 +54,6 @@ class CrashGenerationClient { // The returned CrashGenerationClient* is owned by the caller of // this function. static CrashGenerationClient* TryCreate(int server_fd); - - private: - DISALLOW_COPY_AND_ASSIGN(CrashGenerationClient); }; } // namespace google_breakpad diff --git a/src/client/linux/crash_generation/crash_generation_server.cc b/src/client/linux/crash_generation/crash_generation_server.cc index 56cc0cd7..e3270c9d 100644 --- a/src/client/linux/crash_generation/crash_generation_server.cc +++ b/src/client/linux/crash_generation/crash_generation_server.cc @@ -26,6 +26,10 @@ // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +#ifdef HAVE_CONFIG_H +#include <config.h> // Must come first +#endif + #include <assert.h> #include <dirent.h> #include <fcntl.h> |