barrier/io/CInputStreamFilter.h
crs ed8ed72f26 synergy hook DLL will now restart itself if a client tries to
init() it while it's already running.  fixed an uninitialized
pointer bug in CServer and some cleanup-on-error code in
CMSWindowsPrimaryScreen.  also added timeout to read() on
IInputStream and a heartbeat sent by clients so the server
can disconnect clients that are dead but never reset the TCP
connection.  previously the server would keep these dead
clients around forever and if the user was locked on the
client screen for some reason then the server would have to
be rebooted (or the server would have to be killed via a
remote login).
2002-06-26 16:31:48 +00:00

29 lines
536 B
C++

#ifndef CINPUTSTREAMFILTER_H
#define CINPUTSTREAMFILTER_H
#include "IInputStream.h"
class CInputStreamFilter : public IInputStream {
public:
CInputStreamFilter(IInputStream*, bool adoptStream = true);
~CInputStreamFilter();
// manipulators
// accessors
// IInputStream overrides
virtual void close() = 0;
virtual UInt32 read(void*, UInt32 maxCount, double timeout) = 0;
virtual UInt32 getSize() const = 0;
protected:
IInputStream* getStream() const;
private:
IInputStream* m_stream;
bool m_adopted;
};
#endif