OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome_frame/urlmon_upload_data_stream.h" | 5 #include "chrome_frame/urlmon_upload_data_stream.h" |
6 | 6 |
7 #include "net/base/io_buffer.h" | 7 #include "net/base/io_buffer.h" |
8 #include "net/base/net_errors.h" | 8 #include "net/base/net_errors.h" |
9 | 9 |
10 void UrlmonUploadDataStream::Initialize(net::UploadData* upload_data) { | 10 void UrlmonUploadDataStream::Initialize(net::UploadData* upload_data) { |
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
90 return E_POINTER; | 90 return E_POINTER; |
91 | 91 |
92 memset(stat_stg, 0, sizeof(STATSTG)); | 92 memset(stat_stg, 0, sizeof(STATSTG)); |
93 if (0 == (grf_stat_flag & STATFLAG_NONAME)) { | 93 if (0 == (grf_stat_flag & STATFLAG_NONAME)) { |
94 const wchar_t kStreamBuffer[] = L"PostStream"; | 94 const wchar_t kStreamBuffer[] = L"PostStream"; |
95 stat_stg->pwcsName = | 95 stat_stg->pwcsName = |
96 static_cast<wchar_t*>(::CoTaskMemAlloc(sizeof(kStreamBuffer))); | 96 static_cast<wchar_t*>(::CoTaskMemAlloc(sizeof(kStreamBuffer))); |
97 lstrcpy(stat_stg->pwcsName, kStreamBuffer); | 97 lstrcpy(stat_stg->pwcsName, kStreamBuffer); |
98 } | 98 } |
99 stat_stg->type = STGTY_STREAM; | 99 stat_stg->type = STGTY_STREAM; |
100 stat_stg->cbSize.QuadPart = upload_data_->GetContentLength(); | 100 stat_stg->cbSize.QuadPart = upload_data_->GetContentLengthSyncHack(); |
101 return S_OK; | 101 return S_OK; |
102 } | 102 } |
OLD | NEW |