 
                 if downloadTask == progressReporter.tasks[i].downloadTask {
 
+                    let didReceiveDataBytes = Int64(data.length)
                     progressReporter.tasks[i].progress.completedUnitCount += didReceiveDataBytes
+                    progressReporter.tasks[i].tempData.appendData(data)
 
                     progressReporter.reportProgress?(progressReporter.totalProgress)
 

        if !attachmentURLString.isEmpty && message.localAttachmentName.isEmpty, let URL = NSURL(string: attachmentURLString) {

            attachmentDownloadTask = sharedDownloader.session.dataTaskWithURL(URL)
//            attachmentDownloadTask = sharedDownloader.session.dataTaskWithURL(URL, completionHandler: { (data, response, error) -> Void in
//                print("YepDownloader final data.lenght: \(data!.length)")
//            })

            attachmentFinishedAction = { data in


        }

        return false
    }

    private func finishDownloadTask(downloadTask: NSURLSessionDataTask) {

        for i in 0..<progressReporters.count {

            for j in 0..<progressReporters[i].tasks.count {

                if downloadTask == progressReporters[i].tasks[j].downloadTask {

                    let finishedAction = progressReporters[i].tasks[j].finishedAction
                    let data = progressReporters[i].tasks[j].tempData
                    finishedAction(data)

                    progressReporters[i].finishedTasksCount++

                    // 若任务都已完成，移除此 progressReporter
                    if progressReporters[i].finishedTasksCount == progressReporters[i].tasks.count {
                        progressReporters.removeAtIndex(i)
                    }
                    
                    return
                }
            }
        }
    }

    func URLSession(session: NSURLSession, dataTask: NSURLSessionDataTask, didReceiveResponse response: NSURLResponse, completionHandler: (NSURLSessionResponseDisposition) -> Void) {
