Add StreamHandle::operator bool
This commit is contained in:
parent
a8b50e9a69
commit
10fc7da79d
@ -152,6 +152,8 @@ namespace spades {
|
||||
return o->stream;
|
||||
}
|
||||
|
||||
StreamHandle::operator bool() const { return o->stream; }
|
||||
|
||||
void StreamHandle::Reset() {
|
||||
if (o) {
|
||||
o->Release();
|
||||
|
@ -87,5 +87,6 @@ namespace spades {
|
||||
void Reset();
|
||||
IStream *operator->() const;
|
||||
operator IStream *() const;
|
||||
operator bool() const;
|
||||
};
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user