Simplified internal checks for requests and responses

This commit is contained in:
Pierre-Olivier Latour
2014-04-08 23:00:21 -07:00
parent 289059c875
commit c454dc4e8e
6 changed files with 7 additions and 20 deletions
+3
View File
@@ -222,6 +222,7 @@
}
- (BOOL)performOpen:(NSError**)error {
DCHECK(_type);
if (_opened) {
DNOT_REACHED();
return NO;
@@ -239,10 +240,12 @@
}
- (NSData*)performReadData:(NSError**)error {
DCHECK(_opened);
return [_reader readData:error];
}
- (void)performClose {
DCHECK(_opened);
[_reader close];
}