From 63636d3d211b92e5adb9653db9b06b62278cb889 Mon Sep 17 00:00:00 2001 From: "Matthias P. Braendli" Date: Wed, 22 Jan 2014 21:11:03 +0100 Subject: correct 'forbid copying a DabInputCompatible' --- .gitignore | 1 + src/dabInput.h | 8 +++++--- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 7a169cb..18a091b 100644 --- a/.gitignore +++ b/.gitignore @@ -28,3 +28,4 @@ cscope.out ctags tags .clang_complete +.ycm_extra_conf.py* diff --git a/src/dabInput.h b/src/dabInput.h index e5c89da..12823b8 100644 --- a/src/dabInput.h +++ b/src/dabInput.h @@ -55,6 +55,8 @@ class DabInputBase { virtual int close() = 0; virtual ~DabInputBase() {}; + protected: + DabInputBase() {}; }; /* Wrapper class for old-style dabInputOperations inputs */ @@ -67,9 +69,6 @@ class DabInputCompatible : public DabInputBase { virtual ~DabInputCompatible() { m_ops.clean(&args); } - DabInputCompatible& operator=(const DabInputCompatible& other); - DabInputCompatible(const DabInputCompatible& other); - virtual int open(const std::string name) { return m_ops.open(args, name.c_str()); } @@ -103,6 +102,9 @@ class DabInputCompatible : public DabInputBase { virtual dabInputOperations getOpts() { return m_ops; } private: + DabInputCompatible& operator=(const DabInputCompatible& other); + DabInputCompatible(const DabInputCompatible& other); + dabInputOperations m_ops; void* args; }; -- cgit v1.2.3