More socket work
[ITFoundation.git] / ITByteStream.m
index eff6eb7..4d34eb0 100755 (executable)
     return ret;
 }
 
+-(NSData*) readAllData
+{
+    NSData *ret;
+    [lock lock];
+    ret = [data autorelease];
+    data = [[NSMutableData alloc] init];
+    [lock unlock];
+    return ret;
+}
+
 -(void) writeData:(NSData*)_data
 {
     [lock lock];