From 91bdac7f768e538a2e25b04347b747b1902e3159 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Thu, 26 Jun 2008 02:48:06 +0200 Subject: Verhindere das Kopieren von Connection- und Listener-Objekten --- src/Net/Connection.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/Net/Connection.h') diff --git a/src/Net/Connection.h b/src/Net/Connection.h index a5bda5a..0ef3ebf 100644 --- a/src/Net/Connection.h +++ b/src/Net/Connection.h @@ -63,6 +63,10 @@ class Connection { return (transR.length == transR.transmitted); } + // Prevent shallow copy + Connection(const Connection &o); + Connection& operator=(const Connection &o); + protected: struct ConnectionHeader { unsigned char m; @@ -114,7 +118,7 @@ class Connection { bool isConnected() const {return (state != DISCONNECTED);} bool isConnecting() { - return (state == HANDSHAKE || state == CONNECTION_HEADER); + return (state == HANDSHAKE || state == CONNECTION_HEADER); } const IPAddress* getPeer() {return peer;} -- cgit v1.2.3