소스 검색

Don't allow copying BufferedFile

Tatsuhiro Tsujikawa 14 년 전
부모
커밋
6034474550
1개의 변경된 파일4개의 추가작업 그리고 0개의 파일을 삭제
  1. 4 0
      src/BufferedFile.h

+ 4 - 0
src/BufferedFile.h

@@ -70,6 +70,10 @@ public:
   // Mode for writing
   static const std::string WRITE;
 private:
+  // Don't allow copying
+  BufferedFile(const BufferedFile&);
+  BufferedFile& operator=(const BufferedFile&);
+
   FILE* fp_;
   // true when file has been opened.
   bool open_;