Streaming a file as it gets written?

  • I'm trying to

    NSURL *cgiUrl = [NSURL
    URLWithString:@"http://api-dev.melodis.com/mobile/search/sing"];
    NSMutableURLRequest *postRequest = [NSMutableURLRequest requestWithURL:cgiUrl];

    //setting the headers:
    [postRequest setHTTPMethod:@"POST"];
    [postRequest addValue: @"application/octet-stream" forHTTPHeaderField:
    @"Content-Type"];

    //adding the body:
    fileStream = [[NSInputStream inputStreamWithFileAtPath:
    @"/tmp/midomi.amr"] retain];
    [postRequest setHTTPBodyStream: fileStream];

    // Make the request
    NSURLConnection *theConnection=[[NSURLConnection alloc]
    initWithRequest:postRequest:  delegate:self];
previous month january 2008 next month
MTWTFSS
  1 2 3 4 5 6
7 8 9 10 11 12 13
14 15 16 17 18 19 20
21 22 23 24 25 26 27
28 29 30 31      
Go to today